forked from bylexus/docker-apache-php7
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run
18 lines (15 loc) · 890 Bytes
/
run
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash
set -e
PHP_ERROR_REPORTING=${PHP_ERROR_REPORTING:-"E_ALL"}
sed -ri 's/^display_errors\s*=\s*Off/display_errors = On/g' /etc/php/7.0/apache2/php.ini
sed -ri 's/^display_errors\s*=\s*Off/display_errors = On/g' /etc/php/7.0/cli/php.ini
sed -ri "s/^error_reporting\s*=.*$//g" /etc/php/7.0/apache2/php.ini
sed -ri "s/^error_reporting\s*=.*$//g" /etc/php/7.0/cli/php.ini
echo "error_reporting = $PHP_ERROR_REPORTING" >> /etc/php/7.0/apache2/php.ini
echo "error_reporting = $PHP_ERROR_REPORTING" >> /etc/php/7.0/cli/php.ini
TIMEZONE=${TIMEZONE:-"Europe/Paris"}
sed -ri "s/^date.timezone\s*=.*$//g" /etc/php/7.0/apache2/php.ini
sed -ri "s/^date.timezone\s*=.*$//g" /etc/php/7.0/cli/php.ini
echo "date.timezone = $TIMEZONE" >> /etc/php/7.0/apache2/php.ini
echo "date.timezone = $TIMEZONE" >> /etc/php/7.0/cli/php.ini
source /etc/apache2/envvars && exec /usr/sbin/apache2 -DFOREGROUND