Commit 9329a5e3 by Kevin Falcone Committed by GitHub

Merge pull request #15440 from edx/jibsheet/tweak-video-upload-pipeline-s3-access

Change to validate=False which emulates django-storages
parents e408feff f6827a9a
......@@ -431,7 +431,11 @@ def storage_service_bucket():
settings.AWS_ACCESS_KEY_ID,
settings.AWS_SECRET_ACCESS_KEY
)
return conn.get_bucket(settings.VIDEO_UPLOAD_PIPELINE["BUCKET"])
# We don't need to validate our bucket, it requires a very permissive IAM permission
# set since behind the scenes it fires a HEAD request that is equivalent to get_all_keys()
# meaning it would need ListObjects on the whole bucket, not just the path used in each
# environment (since we share a single bucket for multiple deployments in some configurations)
return conn.get_bucket(settings.VIDEO_UPLOAD_PIPELINE["BUCKET"], validate=False)
def storage_service_key(bucket, file_name):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment