Add HSTS header and discovery config

This commit is contained in:
Ruben Hensen
2025-02-04 14:02:34 +01:00
parent 070f30769a
commit baefe1258d
+25 -24
View File
@@ -53,30 +53,31 @@ spec:
# kubernetes.io/tls-acme: "true" # kubernetes.io/tls-acme: "true"
cert-manager.io/cluster-issuer: prod-cluster-issuer cert-manager.io/cluster-issuer: prod-cluster-issuer
# # Keep this in sync with the README.md: # # Keep this in sync with the README.md:
# nginx.ingress.kubernetes.io/server-snippet: |- nginx.ingress.kubernetes.io/server-snippet: |-
# server_tokens off; server_tokens off;
# proxy_hide_header X-Powered-By; add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;";
# rewrite ^/.well-known/webfinger /index.php/.well-known/webfinger last; proxy_hide_header X-Powered-By;
# rewrite ^/.well-known/nodeinfo /index.php/.well-known/nodeinfo last; rewrite ^/.well-known/webfinger /index.php/.well-known/webfinger last;
# rewrite ^/.well-known/host-meta /public.php?service=host-meta last; rewrite ^/.well-known/nodeinfo /index.php/.well-known/nodeinfo last;
# rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json; rewrite ^/.well-known/host-meta /public.php?service=host-meta last;
# location = /.well-known/carddav { rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json;
# return 301 $scheme://$host/remote.php/dav; location = /.well-known/carddav {
# } return 301 $scheme://$host/remote.php/dav;
# location = /.well-known/caldav { }
# return 301 $scheme://$host/remote.php/dav; location = /.well-known/caldav {
# } return 301 $scheme://$host/remote.php/dav;
# location = /robots.txt { }
# allow all; location = /robots.txt {
# log_not_found off; allow all;
# access_log off; log_not_found off;
# } access_log off;
# location ~ ^/(?:build|tests|config|lib|3rdparty|templates|data)/ { }
# deny all; location ~ ^/(?:build|tests|config|lib|3rdparty|templates|data)/ {
# } deny all;
# location ~ ^/(?:autotest|occ|issue|indie|db_|console) { }
# deny all; location ~ ^/(?:autotest|occ|issue|indie|db_|console) {
# } deny all;
}
tls: tls:
- secretName: nextcloud-tls - secretName: nextcloud-tls
hosts: hosts: