matriphe / docker-alpine-php Goto Github PK
View Code? Open in Web Editor NEWPHP FPM and PHP CLI docker image based on Alpine Linux
PHP FPM and PHP CLI docker image based on Alpine Linux
Hello,
Nice Dockerfile. I've experienced an issue in this line though:
sed -i "s|;date.timezone =.*|date.timezone = ${TIMEZONE}|" /etc/php/php.ini
Timezone isn't replaced with the env in php.ini, keeping the original line date.timezone = UTC
in php.ini
. Any idea?
PHP 7.x CLI is actually available now so I was thinking about this division between CLI and FPM, maybe they should be merged?
There is some difference between lean one and one with both but it is about 10MB and that includes xdebug
, opcache
and composer
and those are valuable tools.
These PHP modules are added:
php7-opcache \
php7-xdebug \
php7-phar \
php7 \
and Composer which is in path in /usr/local/bin
. php7
is symlinked as php
in /usr/bin
Configuration files are copied into their place at /etc/php7/conf.d/
.
Xdebug is usually on port 9000
which is the same as php-fpm
so I moved it to 9009 and expose it for local debuging tools.
I've built it and test it locally. There is pull request for this suggestion.
What do you think? ๐
Hi there, I am looking for the smaller php-fpm image around and I think this is exactly what I need, although is there any chance to add Xdebug and Composer support? Let's said I want to use this image for develop using Symfony2 or Laravel which uses Composer and I would like also to debug my code, can you help me to achieve this?
The issue opened in matriphe/docker-alpine-nginx#1 actually belongs here because it is a a change in PHP (tag: fpm7) configuration that prevents connection.
The reason why connection is refused is because it only can listen on 127.0.0.1:9000, and that can be checked in /etc/php7/php-fpm.d/www.conf
line 36.
This fix #4 solves that by fixing proper file.
I copied some of your sed
statements to my own Dockerfile
and noticed the following error:
sed -i "s|post_max_size =.*|max_file_uploads = ${PHP_MAX_POST}|" /etc/php/php.ini && \
You are replacing the post_max_size
config with max_file_uploads
. Just a heads up...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.