Created
February 23, 2023 17:36
-
-
Save nick-cheatwood7/944dcebb841b0dac81ade1827b81f3ea to your computer and use it in GitHub Desktop.
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
{ | |
email [email protected] | |
} | |
https://example.com { | |
encode gzip | |
# Proxy API requests to the backend server | |
handle /api/* { | |
header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" | |
header Content-Type application/json | |
reverse_proxy backend-server:4000 | |
} | |
# Proxy GraphQL requests to the backend server | |
handle /graphql { | |
header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" | |
header Content-Type application/json | |
reverse_proxy backend-server:4000 | |
} | |
handle { | |
root * /var/www/html | |
try_files {path} /index.html | |
file_server | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment