Backport the nginx virthost dotfile conf.

This commit is contained in:
Andrea Dell'Amico 2024-05-03 18:42:30 +02:00
parent 60d51285da
commit f86b1a196d
Signed by: adellam
GPG Key ID: 147ABE6CEB9E20FF
1 changed files with 17 additions and 0 deletions

View File

@ -27,6 +27,15 @@ server {
return 404;
}
{% endif %}
{% elif nginx_block_dangerous_dotfiles %}
location ~ /\.(?ht).* {
deny all;
access_log off;
log_not_found off;
return 404;
}
{% endif %}
{% if letsencrypt_acme_install %}
include /etc/nginx/snippets/letsencrypt-proxy.conf;
@ -235,6 +244,14 @@ server {
return 404;
}
{% endif %}
{% elif nginx_block_dangerous_dotfiles %}
location ~ /\.(?ht).* {
deny all;
access_log off;
log_not_found off;
return 404;
}
{% endif %}
{% if haproxy_ips is defined %}
# We are behind haproxy