diff options
| author | Elizabeth Hunt <me@liz.coffee> | 2026-01-04 21:15:44 -0800 |
|---|---|---|
| committer | Elizabeth Hunt <me@liz.coffee> | 2026-01-04 21:15:44 -0800 |
| commit | 681a8af8b192387ada5045ad0d7db53b1ec131b6 (patch) | |
| tree | 5dfac56c69b17001e5fcb92898d64d9261118a3b | |
| parent | acfea7c9e0129168205c374783e7036e5018c9a5 (diff) | |
| download | adelie-681a8af8b192387ada5045ad0d7db53b1ec131b6.tar.gz adelie-681a8af8b192387ada5045ad0d7db53b1ec131b6.zip | |
Fix CORS
| -rw-r--r-- | nginx.conf | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -52,22 +52,33 @@ http { location ~* \.(css|js)$ { expires 30m; add_header Cache-Control "public, max-age=1800" always; + add_header Access-Control-Allow-Origin "*" always; + add_header Access-Control-Allow-Methods "GET, OPTIONS" always; + add_header Access-Control-Allow-Headers "Content-Type" always; } location ~* \.(woff|woff2|ttf|otf|eot)$ { expires 30m; add_header Cache-Control "public, max-age=1800" always; add_header Access-Control-Allow-Origin "*" always; + add_header Access-Control-Allow-Methods "GET, OPTIONS" always; + add_header Access-Control-Allow-Headers "Content-Type" always; } location ~* \.(jpg|jpeg|png|gif|svg|ico|webp)$ { expires 30m; add_header Cache-Control "public, max-age=1800" always; + add_header Access-Control-Allow-Origin "*" always; + add_header Access-Control-Allow-Methods "GET, OPTIONS" always; + add_header Access-Control-Allow-Headers "Content-Type" always; } location / { expires 30m; add_header Cache-Control "public, max-age=1800" always; + add_header Access-Control-Allow-Origin "*" always; + add_header Access-Control-Allow-Methods "GET, OPTIONS" always; + add_header Access-Control-Allow-Headers "Content-Type" always; try_files $uri $uri/ =404; } } |
