Mastodon nginx: fix CORS on /instance

This commit is contained in:
Alex Gleason 2022-05-16 21:57:08 -05:00
parent 02edd5cd36
commit e819d9560a
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7

View file

@ -104,6 +104,11 @@ server {
# Enable CORS so we can fetch them.
location /instance {
add_header Access-Control-Allow-Origin "*";
if ($request_method = 'OPTIONS') {
add_header Access-Control-Allow-Origin "*";
return 204;
}
}
# Soapbox ServiceWorker.