Skip to content

Instantly share code, notes, and snippets.

@boopathi
Forked from seekshiva/gist:4386309
Last active December 10, 2015 05:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save boopathi/4386980 to your computer and use it in GitHub Desktop.
Save boopathi/4386980 to your computer and use it in GitHub Desktop.
upstream thin {
server unix:/tmp/thin.0.sock;
server unix:/tmp/thin.1.sock;
server unix:/tmp/thin.2.sock;
}
server {
listen 80;
server_name my-domain-name.com
location /status.html {
proxy_pass http://thin;
}
location / {
proxy_pass http://thin;
}
if ($http_x_forwarded_proto = 'http') {
#return 301 https://$server_name$request_uri;
# (or)
rewrite ^ https://$server_name$request_uri? permanent;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment