Refactors PHP_DISPLAY_ERRORS configuration variable

In order to follow the same philosophy as the original image we
define a default value for PHP_DISPLAY_ERRORS in the Dockerfile
parent 620de77b
FROM mattrayner/lamp:latest-1604 FROM mattrayner/lamp:latest-1604
ENV PHP_DISPLAY_ERRORS Off
ADD run.sh /run.sh ADD run.sh /run.sh
...@@ -3,11 +3,8 @@ ...@@ -3,11 +3,8 @@
VOLUME_HOME="/var/lib/mysql" VOLUME_HOME="/var/lib/mysql"
sed -ri -e "s/^upload_max_filesize.*/upload_max_filesize = ${PHP_UPLOAD_MAX_FILESIZE}/" \ sed -ri -e "s/^upload_max_filesize.*/upload_max_filesize = ${PHP_UPLOAD_MAX_FILESIZE}/" \
-e "s/^post_max_size.*/post_max_size = ${PHP_POST_MAX_SIZE}/" /etc/php/5.6/apache2/php.ini -e "s/^post_max_size.*/post_max_size = ${PHP_POST_MAX_SIZE}/" \
-e "s/^display_errors.*/display_errors = ${PHP_DISPLAY_ERRORS}/" /etc/php/5.6/apache2/php.ini
if [ "$PHP_DISPLAY_ERRORS" == "On" ];then
sed -ri -e "s/^display_errors.*/display_errors = On/" /etc/php/5.6/apache2/php.ini
fi
sed -i "s/export APACHE_RUN_GROUP=www-data/export APACHE_RUN_GROUP=staff/" /etc/apache2/envvars sed -i "s/export APACHE_RUN_GROUP=www-data/export APACHE_RUN_GROUP=staff/" /etc/apache2/envvars
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment