This repository has been archived by the owner on Apr 19, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.7-apache-nl
47 lines (44 loc) · 1.63 KB
/
Dockerfile.7-apache-nl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
ARG PHP_TAG=7-apache
FROM php:$PHP_TAG
ARG LOCALE=nl_NL
ARG ENV=production
# install dependencies
RUN apt update && apt upgrade -y && \
apt install -y git locales libicu-dev unzip zlib1g-dev libzmq3-dev libzip-dev libpng++-dev && \
docker-php-ext-configure intl && \
docker-php-ext-install intl && \
docker-php-ext-install mysqli && \
docker-php-ext-install pdo_mysql && \
docker-php-ext-install zip && \
docker-php-ext-install gd && \
docker-php-ext-configure gd && \
pecl install grpc && \
pecl install protobuf && \
git clone git://github.com/mkoppanen/php-zmq.git && \
cd php-zmq && \
phpize && \
./configure && \
make install && \
cd .. && \
rm -fr php-zmq && \
docker-php-ext-enable zmq && \
docker-php-ext-enable grpc && \
docker-php-ext-enable protobuf && \
# generate locale
sed -i 's/^# *\($LOCALE.UTF-8\)/\1/' /etc/locale.gen && \
locale-gen && \
mv "$PHP_INI_DIR/php.ini-$ENV" "$PHP_INI_DIR/php.ini" && \
# clean up
apt purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false -o APT::AutoRemove::SuggestsImportant=false $BUILD_LIBS && \
apt -y autoremove && \
apt clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /var/cache/* && \
# enable debug options
if [ $ENV = "development" ] ; then \
pecl install xdebug; \
docker-php-ext-enable xdebug; \
echo "error_reporting = E_ALL" >> $PHP_INI_DIR/conf.d/docker-php-ext-xdebug.ini; \
echo "display_startup_errors = On" >> $PHP_INI_DIR/conf.d/docker-php-ext-xdebug.ini; \
echo "display_errors = On" >> $PHP_INI_DIR/conf.d/docker-php-ext-xdebug.ini; \
echo "xdebug.remote_enable=1" >> $PHP_INI_DIR/conf.d/docker-php-ext-xdebug.ini; \
fi ;