0
0
Fork 0
mirror of https://github.com/nextcloud/docker.git synced 2025-07-04 16:04:10 +02:00

Allow Referrer-Policy header to be configured

This commit is contained in:
Louis Matthijssen 2018-09-07 22:09:02 +02:00
parent 4549fd56a9
commit 6bcc8c6770
No known key found for this signature in database
GPG key ID: 188D1103419E4C20
5 changed files with 23 additions and 7 deletions

View file

@ -95,14 +95,18 @@ RUN { \
VOLUME /var/www/html
RUN a2enmod rewrite remoteip ;\
RUN a2enmod rewrite remoteip env headers ;\
{\
echo RemoteIPHeader X-Real-IP ;\
echo RemoteIPTrustedProxy 10.0.0.0/8 ;\
echo RemoteIPTrustedProxy 172.16.0.0/12 ;\
echo RemoteIPTrustedProxy 192.168.0.0/16 ;\
} > /etc/apache2/conf-available/remoteip.conf;\
a2enconf remoteip
{\
echo PassEnv APACHE_REFERRER_POLICY ;\
echo Header set Referrer-Policy "%{APACHE_REFERRER_POLICY}e" "env=APACHE_REFERRER_POLICY" ;\
} > /etc/apache2/conf-available/referrerpolicy.conf;\
a2enconf remoteip referrerpolicy
ENV NEXTCLOUD_VERSION 12.0.11