rabbah commented on a change in pull request #4329: Redirect http to https and 
other nginx config cleanup.
URL: 
https://github.com/apache/incubator-openwhisk/pull/4329#discussion_r264204973
 
 

 ##########
 File path: ansible/roles/nginx/templates/nginx.conf.j2
 ##########
 @@ -89,20 +89,27 @@ http {
 {# Turn off sending information about the server to the client #}
     server_tokens off;
 
+    # Redirect all http to https.
+    server {
+        listen 80 default_server;
+        server_name _;
+        return 301 https://$host$request_uri;
 
 Review comment:
   i can remove this if it's controversial -- my thinking was that we have not 
supported port 80 but the port was exposed... so this change redirect http to 
https.
   
   i think the reason not to support http in the project is that it 
wouldn't/shouldn't be used in production, and we've had support for self signed 
cert for local development, and without a test it would rot.
   
   incidentally, i could add a test for the http redirect.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to