Created
October 6, 2019 17:39
-
-
Save mezbahalam/be2424e138838f5d2e1b402c2f5cd13e to your computer and use it in GitHub Desktop.
@habib debug
This file contains 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
upstream app { | |
# Path to Puma SOCK file, as defined previously | |
server unix:/home/deployer/fastfood/shared/tmp/sockets/puma.sock fail_timeout=0; | |
} | |
server { | |
listen 80; | |
server_name localhost; | |
root /home/deployer/fastfood/current/public; | |
location / { | |
try_files $uri/index.html $uri @app; | |
} | |
location @app { | |
proxy_set_header X-Forwarded-Proto $scheme; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header Host $host; | |
proxy_redirect off; | |
proxy_http_version 1.1; | |
proxy_set_header Connection ''; | |
proxy_pass http://app; | |
} | |
location ~ ^/(assets|fonts|system)/|favicon.ico|robots.txt { | |
gzip_static on; | |
expires max; | |
add_header Cache-Control public; | |
} | |
error_page 500 502 503 504 /500.html; | |
client_max_body_size 4G; | |
keepalive_timeout 10; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment