diff options
Diffstat (limited to 'nginx.conf')
| -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; } } |
