Created
August 14, 2013 06:56
-
-
Save kkxlkkxllb/6228610 to your computer and use it in GitHub Desktop.
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
| upstream imc_backend { | |
| server unix:/data/app/imc/current/tmp/sockets/unicorn.sock fail_timeout=0; | |
| } | |
| server { | |
| listen 8081; | |
| server_name imc.unionpaysmart.com; | |
| access_log /var/log/nginx/imc-uionpaysmart-com-access.log main; | |
| error_log /var/log/nginx/imc-unionpaysmart-com-error.log; | |
| location / { | |
| proxy_redirect off; | |
| #proxy_set_header Host $host; | |
| proxy_set_header X-Real-IP $remote_addr; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header Host $host:$server_port; | |
| proxy_ignore_client_abort on; | |
| proxy_read_timeout 300s; | |
| proxy_send_timeout 300s; | |
| proxy_connect_timeout 300; | |
| #fastcgi_send_timeout 300; | |
| #fastcgi_connect_timeout 300; | |
| #fastcgi_read_timeout 300; | |
| if (!-f $request_filename) { | |
| proxy_pass http://imc_backend; | |
| break; | |
| } | |
| } | |
| location ~ /\.ht { | |
| deny all; | |
| } | |
| location ~* ^.+.(jpg|jpeg|gif|png|ico|css|zip|tgz|gz|rar|bz2|doc|xls|exe|pdf|ppt|tar|mid|midi|wav|bmp|rtf)$ { | |
| root /data/app/imc/current/public; | |
| expires 30d; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment