Skip to content

Instantly share code, notes, and snippets.

@gboddin
Last active September 6, 2019 13:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gboddin/45976e74f8c6eae529cfd4df903d83fe to your computer and use it in GitHub Desktop.
Save gboddin/45976e74f8c6eae529cfd4df903d83fe to your computer and use it in GitHub Desktop.
rewrite to /index
server {
location / {
gzip on;
gzip_vary on;
gzip_min_length 10240;
gzip_proxied expired no-cache no-store private auth;
gzip_types text/plain text/css text/xml text/javascript application/x-javascript application/xml;
gzip_disable "MSIE [1-6]\.";
root /usr/share/nginx/html;
try_files $uri $uri/ /index.html;
}
}
@gboddin
Copy link
Author

gboddin commented Apr 26, 2019

Most used config in static hosting + rewrite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment