server { listen 8910 default_server; root /usr/share/nginx/html; # Add global header add_header X-Awesomeness 9000; # 1 hour cache for css and js location ~* \.(?:css|js)$ { expires 1h; add_header Pragma public; add_header Cache-Control "public"; access_log off; } # 7 days cache for image assets location ~* \.(?:ico|gif|jpe?g|png)$ { expires 7d; add_header Pragma public; add_header Cache-Control "public"; access_log off; } location / { try_files $uri $uri/ /index.html; } }