Skip to content

Commit

Permalink
Add CORS config to S3 media bucket for igv.js (#3227)
Browse files Browse the repository at this point in the history
  • Loading branch information
hackdna committed Feb 22, 2019
1 parent 3875de8 commit b5eb715
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions deployment/terraform/modules/s3/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,14 @@ PUBLIC_ACCESS
enabled = true
}

# https://github.com/igvteam/igv.js/wiki/Data-Server-Requirements#cross-origin-resource-sharing-cors
cors_rule {
allowed_headers = ["Range"]
allowed_methods = ["GET", "HEAD"]
allowed_origins = ["${var.origin_protocol}://${var.origin_domain}"]
max_age_seconds = 600
}

lifecycle_rule {
id = "Delete non-current object versions and expired delete markers"
enabled = true
Expand Down

0 comments on commit b5eb715

Please sign in to comment.