191b13ea40bfb10f4c9e6eea0e63b0a2b090db3b
[lhc/ateliers.git] / etc / nginx / site.d / burette / site.conf
1 server_name
2 burettes.heureux-cyclage.org
3 burette.atelierdynamo.fr
4 burette.cyclocoop.heureux-cyclage.org
5 burette.cyclocoop.org
6 burette.dynamo.heureux-cyclage.org
7 burette.ptitvelo.heureux-cyclage.org
8 burette.ptitvelo.net
9 demo.burette.ptitvelo.net
10 burette.velosenville.org
11 demo.burette.velosenville.org;
12
13 client_body_buffer_size 1024k;
14 client_max_body_size 10m;
15
16 proxy_buffers 16 64k;
17 proxy_buffer_size 128k;
18
19 location ~ /\. {
20 access_log off;
21 deny all;
22 log_not_found off;
23 }
24 location / {
25 proxy_next_upstream error timeout
26 invalid_header
27 http_500
28 http_502
29 http_503;
30 # NOTE: force timeouts if the backend dies.
31 proxy_pass http://openerp7_burette;
32 proxy_redirect off;
33 # NOTE: by default, do not forward anything
34 proxy_read_timeout 500;
35 proxy_set_header Host $host;
36 proxy_set_header X-Forward-For $proxy_add_x_forwarded_for;
37 proxy_set_header X-Forwarded-Proto https;
38 # NOTE: let the OpenERP web service know that we're using HTTPS,
39 # otherwise it will generate URL using http:// and not https://
40 proxy_set_header X-Real-IP $remote_addr;
41 }
42
43 location ~* ^/web/static/ {
44 # NOTE: cache some static data in memory for 60mins;
45 # under heavy load this should relieve stress on the OpenERP web interface a bit.
46 expires 864000;
47 proxy_buffering on;
48 proxy_cache_valid 200 60m;
49 proxy_pass http://openerp7_burette;
50 }
51
52 # vim: ft=sh