Skip to content

Commit

Permalink
use http_origin as origin for all requests
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Jul 21, 2021
1 parent 8b7892c commit 7c332ef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions vendor/docker/webapp.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ server {

location / {
# enable CORS
set $cors '';
if ($http_origin ~* 'https?://(localhost:3000|localhost:4200|doi.stage.datacite.org|commons.stage.datacite.org|doi.datacite.org|commons.datacite.org)') {
set $cors 'true';
}
set $cors 'true';
# if ($http_origin ~* 'https?://(localhost:3000|localhost:4200|doi.stage.datacite.org|commons.stage.datacite.org|doi.datacite.org|commons.datacite.org)') {
# set $cors 'true';
# }

# always is required to add headers even if response's status is 4xx or 5xx
if ($cors = 'true') {
Expand Down

0 comments on commit 7c332ef

Please sign in to comment.