-
-
Save jovanimoura/c8aed02a90ed7e9c2ed2bf7208254dd4 to your computer and use it in GitHub Desktop.
odoo nginx config
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
server { | |
listen 80 default_server; | |
#rewrite ^/.*$ https://$host$request_uri? permanent; #Uncomment this line in case you want to use https only | |
#server_name {{ODOO_DOMAIN}}; | |
include odoo_params; | |
location /longpolling { | |
proxy_pass http://127.0.0.1:8072; | |
} | |
location / { | |
proxy_pass http://127.0.0.1:8069; | |
} | |
} |
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
charset utf-8; | |
location = /favicon.ico { | |
return 404; | |
} | |
## increase proxy buffer to handle some OpenERP web requests | |
proxy_buffers 16 64k; | |
proxy_buffer_size 128k; | |
## set headers | |
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 X-Forwarded-Proto $scheme; | |
proxy_read_timeout 600s; #set centrally in nginx.conf | |
client_max_body_size 200m; | |
#general proxy settings | |
proxy_next_upstream error timeout invalid_header http_500 http_502 http_503; | |
# by default, do not forward anything | |
proxy_redirect off; | |
proxy_buffering off; | |
location ~* /web/static/ { | |
proxy_cache_valid 200 90m; | |
proxy_buffering on; | |
expires 864000; | |
proxy_pass http://127.0.0.1:8069; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment