commit | author | age
|
3c8b10
|
1 |
FROM debian:8.0 |
dd4973
|
2 |
MAINTAINER Alex Brandt <alunduil@alunduil.com> |
AB |
3 |
|
|
4 |
EXPOSE 80 443 |
|
5 |
|
|
6 |
RUN apt-get -qq update |
361037
|
7 |
RUN apt-get install -qq apache2-mpm-event ca-certificates |
dd4973
|
8 |
|
96832a
|
9 |
RUN sed -e 's|/var/www/html|/var/www/public_html|' -e 's@\(Log \+\)[^ ]\+@\1"|/bin/cat"@' -i /etc/apache2/sites-available/000-default.conf |
3c8b10
|
10 |
RUN a2ensite 000-default |
616f88
|
11 |
|
96832a
|
12 |
RUN sed -e 's|/var/www/html|/var/www/public_html|' -e 's@\(Log \+\)[^ ]\+@\1"|/bin/cat"@' -i /etc/apache2/sites-available/default-ssl.conf |
3c8b10
|
13 |
RUN sed -e '/SSLCertificateKeyFile/s|ssl-cert-snakeoil.key|ssl-cert.key|' -e '/SSLCertificateFile/s|ssl-cert-snakeoil.pem|ssl-cert.pem|' -i /etc/apache2/sites-available/default-ssl.conf |
616f88
|
14 |
RUN ln -snf ssl-cert-snakeoil.pem /etc/ssl/certs/ssl-cert.pem |
AB |
15 |
RUN ln -snf ssl-cert-snakeoil.key /etc/ssl/private/ssl-cert.key |
|
16 |
RUN a2ensite default-ssl |
dd4973
|
17 |
|
AB |
18 |
RUN a2enmod expires |
|
19 |
RUN a2enmod headers |
616f88
|
20 |
RUN a2enmod ssl |
dd4973
|
21 |
|
AB |
22 |
RUN apt-get install -qq php5 php-pear php5-mysql php5-pgsql php5-sqlite |
b45f9a
|
23 |
RUN pear install mail_mime mail_mimedecode net_smtp net_idna2-beta auth_sasl net_sieve crypt_gpg |
dd4973
|
24 |
|
AB |
25 |
RUN rm -rf /var/www |
|
26 |
ADD . /var/www |
|
27 |
|
|
28 |
RUN echo -e '<?php\n$config = array();\n' > /var/www/config/config.inc.php |
|
29 |
RUN rm -rf /var/www/installer |
|
30 |
|
|
31 |
RUN . /etc/apache2/envvars && chown -R ${APACHE_RUN_USER}:${APACHE_RUN_GROUP} /var/www/temp /var/www/logs |
|
32 |
|
|
33 |
ENTRYPOINT [ "/usr/sbin/apache2ctl", "-D", "FOREGROUND" ] |
|
34 |
CMD [ "-k", "start" ] |