1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
| cat << EOF > /etc/nginx/conf.d/graphite.conf upstream django { server unix:///opt/graphite/conf/uwsgi.sock; } server { listen 8001; charset utf-8; client_max_body_size 75M;
location /static { alias /opt/graphtie/webapp/content; } location /static/admin { alias /opt/graphtie/webapp/static/admin; } location / { auth_basic "Restricted Area"; uwsgi_pass django; include uwsgi_params; } }
server { listen 8002; charset utf-8; client_max_body_size 75M; allow 127.0.0.1; deny all; location /static { alias /opt/graphtie/webapp/content; } location /static/admin { alias /opt/graphite/webapp/static/admin; } location / { uwsgi_pass django; include uwsgi_params; } }
EOF
|