Much like my previous post on redirect HTTP to HTTPS for IIS behind AWS’s Elastic Load Balancer, I started googling around for a solution for nginx. What I’ve put in place works when placed in the server directive for HTTP traffic:

if ($http_x_forwarded_proto != 'https') {
	rewrite ^(.*) https://$host$1 permanent;
}

However, am wondering if there’s a better/cleaner way to do this? Acknowledging this nginx wiki entry..

Static website hosting with continuous deployment/delivery

While I was researching on static web hosting with Jekyll, one of the most suggested ways to get it up and running for free is by relying...… Continue reading