diff --git a/httpd/bookworm/Dockerfile b/httpd/bookworm/Dockerfile index b869f2bc2dc361c1ef158a92402c044388fc60a1..6556ce01a343a590276fac40bf6848c4f3f98f6b 100644 --- a/httpd/bookworm/Dockerfile +++ b/httpd/bookworm/Dockerfile @@ -15,6 +15,8 @@ RUN apt-get update && \ setcap CAP_NET_BIND_SERVICE=+ep /usr/sbin/apache2 && \ DEBIAN_FRONTEND=noninteractive apt-get purge --auto-remove -y libcap2-bin && \ a2enmod status && \ + sed -i "s@combined@combined expr=\!(%{REMOTE_HOST}=='127.0.0.1'\&\&%{HTTP_USER_AGENT}=='Healthcheck')@" /etc/apache2/sites-available/000-default.conf && \ + sed -i 's@Require local@Require ip 127.0.0.1/8 10.0.0.0/8 172.16.0.0/12 192.0.0.0/24@' /etc/apache2/mods-available/status.conf && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_RUN_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOCK_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOG_DIR" && \ diff --git a/httpd/bullseye/Dockerfile b/httpd/bullseye/Dockerfile index cf65f77033f5851bbe0da2fe9db68313515d9099..6e059346748fe1cb1f04afeb181eb6f79cebe898 100644 --- a/httpd/bullseye/Dockerfile +++ b/httpd/bullseye/Dockerfile @@ -15,6 +15,8 @@ RUN apt-get update && \ setcap CAP_NET_BIND_SERVICE=+ep /usr/sbin/apache2 && \ DEBIAN_FRONTEND=noninteractive apt-get purge --auto-remove -y libcap2-bin && \ a2enmod status && \ + sed -i "s@combined@combined expr=\!(%{REMOTE_HOST}=='127.0.0.1'\&\&%{HTTP_USER_AGENT}=='Healthcheck')@" /etc/apache2/sites-available/000-default.conf && \ + sed -i 's@Require local@Require ip 127.0.0.1/8 10.0.0.0/8 172.16.0.0/12 192.0.0.0/24@' /etc/apache2/mods-available/status.conf && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_RUN_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOCK_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOG_DIR" && \ diff --git a/httpd/buster/Dockerfile b/httpd/buster/Dockerfile index d9db471373f1e023af27a47b453c3b5f6437158f..f852209d1dce6a34fe9d01aad3754067b3726e70 100644 --- a/httpd/buster/Dockerfile +++ b/httpd/buster/Dockerfile @@ -15,6 +15,8 @@ RUN apt-get update && \ setcap CAP_NET_BIND_SERVICE=+ep /usr/sbin/apache2 && \ DEBIAN_FRONTEND=noninteractive apt-get purge --auto-remove -y libcap2-bin && \ a2enmod status && \ + sed -i "s@combined@combined expr=\!(%{REMOTE_HOST}=='127.0.0.1'\&\&%{HTTP_USER_AGENT}=='Healthcheck')@" /etc/apache2/sites-available/000-default.conf && \ + sed -i 's@Require local@Require ip 127.0.0.1/8 10.0.0.0/8 172.16.0.0/12 192.0.0.0/24@' /etc/apache2/mods-available/status.conf && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_RUN_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOCK_DIR" && \ install -d -o "$APACHE_RUN_USER" -g "$APACHE_RUN_GROUP" -m 755 "$APACHE_LOG_DIR" && \