Hello everybody,
I installed an SSL certificate with let’s encrypt:
The installation of the certificate worked without problems and accessing the site via HTTPS works great.
For this to work I also activated the DNS based multitenancy:
What doesn’t work is the automatic redirect from Port 80 to Port 443.
My file “/etc/nginx/conf.d/frappe-bench.conf” (which was generated automatically) contains the following block at the end:
server {
listen 80;
server_name
<my-real-url>.com
;
return 301 https://$host$request_uri;
}
But at the start of the file, another block for the same URL on port 80 was generated which causes the redirect to not work.
Yes, I could manually edit this file and remove the problematic block (which I already tried of course).
BUT: the file got generated through executing “bench setup nginx”, and each execution of this could overwrite my manual edits.
So, why does bench generate two entries for my URL for port 80 at all and what can I do to circumvent this without editing the generated config files manually?
Did I do something wrong when creating the site?
There is no nginx-port set in the “site_config.json” btw.
Thanks in advance
Markus