Last active
June 17, 2022 22:11
-
-
Save pcnoic/648584a7273dd906f058d4eed34dc915 to your computer and use it in GitHub Desktop.
simple nginx conf
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; | |
add_header Access-Control-Allow-Origin *; | |
location / { | |
root /spa; | |
try_files $uri $uri/ /index.html; | |
} | |
# redirect server error pages to the static page /50x.html | |
error_page 500 502 503 504 /50x.html; | |
location = /50x.html { | |
root /pwa; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment