This repository was archived by the owner on Aug 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathDockerfile
59 lines (47 loc) · 2.03 KB
/
Dockerfile
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
48
49
50
51
52
53
54
55
56
57
58
59
FROM wordpress:5.1.1-php5.6-fpm
LABEL maintainer='Florian JUDITH <florian.judith.b@gmail.com>'
RUN apt-get update
RUN apt-get install --no-install-recommends -y tidy csstidy nano netcat
RUN mkdir -p /usr/src/php/ext
# Install needed php extensions: memcached
#
RUN apt-get install --no-install-recommends -y libmemcached-dev && \
curl -o memcached.tgz -SL http://pecl.php.net/get/memcached-2.2.0.tgz && \
tar -xf memcached.tgz -C /usr/src/php/ext/ && \
echo extension=memcached.so >> /usr/local/etc/php/conf.d/memcached.ini && \
rm memcached.tgz && \
mv /usr/src/php/ext/memcached-2.2.0 /usr/src/php/ext/memcached
# set recommended PHP.ini settings
# see https://secure.php.net/manual/en/opcache.installation.php
RUN { \
echo 'opcache.memory_consumption=128'; \
echo 'opcache.interned_strings_buffer=8'; \
echo 'opcache.max_accelerated_files=4000'; \
echo 'opcache.revalidate_freq=2'; \
echo 'opcache.fast_shutdown=1'; \
echo 'opcache.enable_cli=1'; \
} > /usr/local/etc/php/conf.d/opcache-recommended.ini
# Install needed php extensions: memcache
#
RUN curl -o memcache.tgz -SL http://pecl.php.net/get/memcache-3.0.8.tgz && \
tar -xf memcache.tgz -C /usr/src/php/ext/ && \
rm memcache.tgz && \
mv /usr/src/php/ext/memcache-3.0.8 /usr/src/php/ext/memcache
RUN apt-get install -y --no-install-recommends libz-dev && \
curl -o zip.tgz -SL http://pecl.php.net/get/zip-1.15.1.tgz && \
tar -xf zip.tgz -C /usr/src/php/ext/ && \
rm zip.tgz && \
mv /usr/src/php/ext/zip-1.15.1 /usr/src/php/ext/zip
RUN docker-php-ext-install memcached
RUN docker-php-ext-install memcache
RUN docker-php-ext-install zip
# Install needed php extensions: ldap
#
RUN apt-get install --no-install-recommends -y libldap2-dev && \
docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu/ && \
docker-php-ext-install ldap
# Cleanup
RUN rm -rf /var/lib/apt/lists/*
# ENTRYPOINT resets CMD
ENTRYPOINT ["docker-entrypoint.sh"]
CMD ["php-fpm"]