Last active
June 27, 2022 18:54
-
-
Save pcnoic/130375e9bfa7e7cd9c56362047063bc7 to your computer and use it in GitHub Desktop.
SPA NGINX config podhustlr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name localhost; | |
port_in_redirect off; | |
autoindex on; | |
location / { | |
root /spa; | |
index index.html index.htm; | |
# kill cache | |
add_header Last-Modified $date_gmt; | |
add_header Cache-Control 'no-store, no-cache'; | |
if_modified_since off; | |
expires off; | |
etag off; | |
} | |
# redirect server error pages to the static page /50x.html | |
error_page 500 502 503 504 /50x.html; | |
location = /50x.html { | |
root /spa; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment