Comment option to set CORS for GCS bucket
This is originally introduced to enable access from pillar-web javascript to GCS buckets (via the vrview.js library). For the moment it is commented since we do not allow HDRI node_type in all projects.
This commit is contained in:
parent
a248e3285c
commit
0264821189
@ -35,11 +35,19 @@ class GoogleCloudStorageBucket(object):
|
||||
self.bucket = gcs.bucket(bucket_name)
|
||||
# Hardcode the bucket location to EU
|
||||
self.bucket.location = 'EU'
|
||||
# Optionally enable CORS from * (currently only used for vrview)
|
||||
# self.bucket.cors = [
|
||||
# {
|
||||
# "origin": ["*"],
|
||||
# "responseHeader": ["Content-Type"],
|
||||
# "method": ["GET", "HEAD", "DELETE"],
|
||||
# "maxAgeSeconds": 3600
|
||||
# }
|
||||
# ]
|
||||
self.bucket.create()
|
||||
|
||||
self.subdir = subdir
|
||||
|
||||
|
||||
def List(self, path=None):
|
||||
"""Display the content of a subdir in the project bucket. If the path
|
||||
points to a file the listing is simply empty.
|
||||
|
Loading…
x
Reference in New Issue
Block a user