Skip to content

Commit

Permalink
Enable CORS access to Main for COVID-19 site.
Browse files Browse the repository at this point in the history
  • Loading branch information
natefoo committed Apr 27, 2020
1 parent 9a207ef commit 51f31de
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion env/main/templates/nginx/usegalaxy.j2
Expand Up @@ -92,13 +92,26 @@ server {
alias {{ galaxy_server_dir }}/static/favicon.ico;
}

#location /display_applications {
# #add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
# #add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
# if ($http_origin ~ "^https?://(covid19\.galaxyproject\.org|.*\.netlify\.app)$") {
# add_header Access-Control-Allow-Origin $http_origin;
# }
#}

location /_x_accel_redirect {
internal;
alias /;
add_header X-Frame-Options SAMEORIGIN;
add_header X-Content-Type-Options nosniff;
# CORS
add_header Access-Control-Allow-Origin "http://registry.intermine.org";
#add_header Access-Control-Allow-Origin "http://registry.intermine.org";
if ($http_origin ~ "^https?://(covid19\.galaxyproject\.org|.*\.netlify\.app|registry\.intermine\.org)$") {
add_header Access-Control-Allow-Origin $http_origin;
add_header Access-Control-Expose-Headers 'Content-Length,Content-Range';
add_header Access-Control-Allow-Headers 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
}
}

location /_upload {
Expand Down

0 comments on commit 51f31de

Please sign in to comment.