Advertisement
Guest User

Untitled

a guest
Sep 17th, 2012
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1. server {
  2. listen 80;
  3. <------>server_name noc;
  4. location /media/ {
  5. alias /opt/noc/contrib/lib/django/contrib/admin/static/;
  6. gzip on;
  7. gzip_types text/css text/x-js;
  8. }
  9.  
  10. <------>location ~ ^/static/ {
  11. <------> root /opt/noc;
  12. <------> gzip on;
  13. <------> gzip_types text/css text/x-js;
  14. <------>}
  15. <------>location ~ ^/([^/]+)/([^/]+)/(js|css|img)/(.+)$ {
  16. <------> root /opt/noc/;
  17. <--> rewrite ^/([^/]+)/([^/]+)/(js|css|img)/(.+)$
  18. <--><------> /$1/apps/$2/$3/$4 break;
  19. gzip on;
  20. gzip_types text/css text/x-js;
  21. }
  22.  
  23. location / {
  24. proxy_pass http://127.0.0.1:8000/;
  25. gzip on;
  26. gzip_types text/css text/x-js;
  27. }
  28.  
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement