summaryrefslogtreecommitdiffstats
path: root/templates/nginx.j2
diff options
context:
space:
mode:
Diffstat (limited to 'templates/nginx.j2')
-rw-r--r--templates/nginx.j24
1 files changed, 1 insertions, 3 deletions
diff --git a/templates/nginx.j2 b/templates/nginx.j2
index 0e05c02..749c4ba 100644
--- a/templates/nginx.j2
+++ b/templates/nginx.j2
@@ -8,12 +8,11 @@ server {
access_log /var/log/nginx/{{ nginx_domain }}.access.log;
error_log /var/log/nginx/{{ nginx_domain }}.error.log;
-{% if letsencrypt_activate %}
location ^~ /.well-known/acme-challenge {
root {{ letsencrypt_wellknown }};
}
-{% if letsencrypt_https %}
+{% if nginx_ssl %}
location / {
rewrite ^(.*)$ https://{{ nginx_domain }}$1 permanent;
}
@@ -34,7 +33,6 @@ server {
include /etc/nginx/snippets/ssl.conf;
{% endif %}
-{% endif %}
root {{ nginx_root }};