Created
November 19, 2021 10:35
-
-
Save discordianfish/8713a58b25ebb0b456d475f699a2cbc4 to your computer and use it in GitHub Desktop.
minimal nginx config with CORS and COEP headers set
This file contains hidden or 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
daemon off; | |
events {} | |
error_log /dev/stdout info; | |
http { | |
include /usr/local/etc/nginx/mime.types; | |
access_log /dev/stdout; | |
server { | |
listen 9000; | |
location / { | |
add_header Access-Control-Allow-Origin *; | |
add_header 'Cross-Origin-Embedder-Policy' 'require-corp'; | |
add_header 'Cross-Origin-Opener-Policy' 'same-origin'; | |
root /path/to/html; | |
} | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment