From 3e5a3962b67ce1e731ab1855ba957b1931d029b5 Mon Sep 17 00:00:00 2001 From: Eric Nemchik Date: Fri, 28 Oct 2022 08:26:39 -0500 Subject: [PATCH] Fix nextcloud X-Frame-Options warning --- nextcloud.subdomain.conf.sample | 3 ++- nextcloud.subfolder.conf.sample | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/nextcloud.subdomain.conf.sample b/nextcloud.subdomain.conf.sample index c1c846a..ce4b056 100644 --- a/nextcloud.subdomain.conf.sample +++ b/nextcloud.subdomain.conf.sample @@ -1,4 +1,4 @@ -## Version 2021/05/18 +## Version 2022/10/28 # make sure that your dns has a cname set for nextcloud # assuming this container is called "swag", edit your nextcloud container's config # located at /config/www/nextcloud/config/config.php and add the following lines before the ");": @@ -31,6 +31,7 @@ server { set $upstream_proto https; proxy_pass $upstream_proto://$upstream_app:$upstream_port; + proxy_hide_header X-Frame-Options; proxy_max_temp_file_size 2048m; } } diff --git a/nextcloud.subfolder.conf.sample b/nextcloud.subfolder.conf.sample index 717adf5..1920577 100644 --- a/nextcloud.subfolder.conf.sample +++ b/nextcloud.subfolder.conf.sample @@ -1,4 +1,4 @@ -## Version 2021/07/14 +## Version 2022/10/28 # Assuming this container is called "swag", edit your nextcloud container's config # located at /config/www/nextcloud/config/config.php and add the following lines before the ");": # 'trusted_proxies' => ['swag'], @@ -32,6 +32,7 @@ location ^~ /nextcloud/ { proxy_pass $upstream_proto://$upstream_app:$upstream_port; rewrite /nextcloud(.*) $1 break; + proxy_hide_header X-Frame-Options; proxy_max_temp_file_size 2048m; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range;