I followed the guide below, but i still get the error in nextcloud.
has something changed?
i restated letsencrypt, restarted nextcloud, logged out of nextcloud.
looged back in and the warning is still there.
here's my nextcloud.subdomain.conf
Code
# make sure that your dns has a cname set for nextcloud
# assuming this container is called "letsencrypt", edit your nextcloud container's config
# located at /config/www/nextcloud/config/config.php and add the following lines before the ");":
# 'trusted_proxies' => ['letsencrypt'],
# 'overwrite.cli.url' => 'https://nextcloud.your-domain.com/',
# 'overwritehost' => 'nextcloud.your-domain.com',
# 'overwriteprotocol' => 'https',
#
# Also don't forget to add your domain name to the trusted domains array. It should look somewhat like this:
# array (
# 0 => '192.168.0.1:444', # This line may look different on your setup, don't modify it.
# 1 => 'nextcloud.your-domain.com',
# ),
server {
listen 443 ssl;
listen [::]:443 ssl;
server_name nextcloud.*;
include /config/nginx/ssl.conf;
client_max_body_size 0;
add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;";
location / {
include /config/nginx/proxy.conf;
resolver 127.0.0.11 valid=30s;
set $upstream_nextcloud nextcloud;
proxy_max_temp_file_size 2048m;
proxy_pass https://$upstream_nextcloud:443;
}
}
Alles anzeigen
Alles anzeigenYou have to edit your nextcloud.subdomains.conf in the letsencrypt config files -> yourconfigfolder/nginx/proxy-confs/
and add
Source Code
- add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;";
inside the "server {" block
EDIT: restart your letsencrypt and nextcloud dockers afterwards.
EDIT 2: regarding the argument "preload;" at the end please consider this link first and remove it if you don't want this option.