From 40a4cbce450697d926b047087f32cdadfb5d3a1b Mon Sep 17 00:00:00 2001 From: Thabo Date: Mon, 13 Jul 2015 16:53:15 -0700 Subject: [PATCH] redirect all non https requests to https --- src/conf/tc-prod-nginx.conf | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/conf/tc-prod-nginx.conf b/src/conf/tc-prod-nginx.conf index ba91aa96..e7686dcb 100644 --- a/src/conf/tc-prod-nginx.conf +++ b/src/conf/tc-prod-nginx.conf @@ -9,9 +9,7 @@ server { listen [::]:8080 default_server ipv6only=on; if ($http_x_forwarded_proto != "https") { - rewrite ^/challenges https://$http_host$request_uri? permanent; - rewrite ^/challenge-details https://$http_host$request_uri? permanent; - rewrite ^/my-dashboard https://$http_host$request_uri? permanent; + return 301 https://$server_name$request_uri; } set $root_base /home/ubuntu/tc-site;