Last active
August 29, 2015 14:05
-
-
Save jbradach/31ad6d9c84c3be3b5730 to your computer and use it in GitHub Desktop.
Nginx config for Redmine using Puma
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://gist.github.com/jbradach/31ad6d9c84c3be3b5730 | |
upstream puma_redmine { | |
server unix:/home/redmine/redmine/tmp/sockets/redmine.sock fail_timeout=0; | |
#server 127.0.0.1:3000; | |
} | |
server { | |
server_name YOUR.SERVER.NAME; | |
listen 80; | |
root /home/redmine/redmine/public; | |
location / { | |
try_files $uri/index.html $uri.html $uri @ruby; | |
} | |
location @ruby { | |
proxy_set_header Host $http_host; | |
proxy_set_header X-Forwarded-Proto $scheme; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_redirect off; | |
proxy_read_timeout 300; | |
proxy_pass http://puma_redmine; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment