docker/apaches/Dockerfile

12 lines
541 B
Docker
Raw Normal View History

2021-11-10 01:38:24 +01:00
from php:7.4.25-apache
2021-05-09 22:07:17 +02:00
RUN a2enmod remoteip rewrite
2021-05-09 22:07:17 +02:00
RUN echo "RemoteIPHeader X-Forwarded-For" > /etc/apache2/conf-available/remoteip.conf
RUN a2enconf remoteip
RUN sed -i -r 's/^ServerTokens .*/ServerTokens Prod/g' /etc/apache2/conf-available/security.conf
RUN sed -i -r 's/^ServerSignature .*/ServerSignature Off/g' /etc/apache2/conf-available/security.conf
RUN sed -i -E 's/^LogFormat "%h(.*)/LogFormat "%a\1/g' /etc/apache2/apache2.conf
RUN echo "expose_php = Off" > /usr/local/etc/php/conf.d/php_version.ini
CMD ["apache2-foreground"]