From 77857f92f016df78420d1eaa167c2b491c071ad9 Mon Sep 17 00:00:00 2001 From: myvesta <38690722+myvesta@users.noreply.github.com> Date: Sat, 25 Mar 2023 15:39:57 +0100 Subject: [PATCH] https redirect to the same host --- install/debian/10/templates/web/nginx/force-https-legacy.tpl | 2 +- install/debian/10/templates/web/nginx/force-https-public.tpl | 2 +- .../10/templates/web/nginx/force-https-webmail-phpmyadmin.tpl | 2 +- install/debian/10/templates/web/nginx/force-https.tpl | 2 +- install/debian/10/templates/web/nginx/private-force-https.tpl | 2 +- install/debian/11/templates/web/nginx/force-https-legacy.tpl | 2 +- install/debian/11/templates/web/nginx/force-https-public.tpl | 2 +- .../11/templates/web/nginx/force-https-webmail-phpmyadmin.tpl | 2 +- install/debian/11/templates/web/nginx/force-https.tpl | 2 +- install/debian/11/templates/web/nginx/private-force-https.tpl | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/install/debian/10/templates/web/nginx/force-https-legacy.tpl b/install/debian/10/templates/web/nginx/force-https-legacy.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/10/templates/web/nginx/force-https-legacy.tpl +++ b/install/debian/10/templates/web/nginx/force-https-legacy.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/10/templates/web/nginx/force-https-public.tpl b/install/debian/10/templates/web/nginx/force-https-public.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/10/templates/web/nginx/force-https-public.tpl +++ b/install/debian/10/templates/web/nginx/force-https-public.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/10/templates/web/nginx/force-https-webmail-phpmyadmin.tpl b/install/debian/10/templates/web/nginx/force-https-webmail-phpmyadmin.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/10/templates/web/nginx/force-https-webmail-phpmyadmin.tpl +++ b/install/debian/10/templates/web/nginx/force-https-webmail-phpmyadmin.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/10/templates/web/nginx/force-https.tpl b/install/debian/10/templates/web/nginx/force-https.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/10/templates/web/nginx/force-https.tpl +++ b/install/debian/10/templates/web/nginx/force-https.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/10/templates/web/nginx/private-force-https.tpl b/install/debian/10/templates/web/nginx/private-force-https.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/10/templates/web/nginx/private-force-https.tpl +++ b/install/debian/10/templates/web/nginx/private-force-https.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/11/templates/web/nginx/force-https-legacy.tpl b/install/debian/11/templates/web/nginx/force-https-legacy.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/11/templates/web/nginx/force-https-legacy.tpl +++ b/install/debian/11/templates/web/nginx/force-https-legacy.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/11/templates/web/nginx/force-https-public.tpl b/install/debian/11/templates/web/nginx/force-https-public.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/11/templates/web/nginx/force-https-public.tpl +++ b/install/debian/11/templates/web/nginx/force-https-public.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/11/templates/web/nginx/force-https-webmail-phpmyadmin.tpl b/install/debian/11/templates/web/nginx/force-https-webmail-phpmyadmin.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/11/templates/web/nginx/force-https-webmail-phpmyadmin.tpl +++ b/install/debian/11/templates/web/nginx/force-https-webmail-phpmyadmin.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/11/templates/web/nginx/force-https.tpl b/install/debian/11/templates/web/nginx/force-https.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/11/templates/web/nginx/force-https.tpl +++ b/install/debian/11/templates/web/nginx/force-https.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; } diff --git a/install/debian/11/templates/web/nginx/private-force-https.tpl b/install/debian/11/templates/web/nginx/private-force-https.tpl index 851ac0dc..8bdbea42 100644 --- a/install/debian/11/templates/web/nginx/private-force-https.tpl +++ b/install/debian/11/templates/web/nginx/private-force-https.tpl @@ -2,7 +2,7 @@ server { listen %ip%:%proxy_port%; server_name %domain_idn% %alias_idn%; location / { - rewrite ^(.*) https://%domain_idn%$1 permanent; + rewrite ^(.*) https://$host%$1 permanent; } include %home%/%user%/conf/web/*nginx.%domain_idn%.conf_letsencrypt; }