fix(storage): remove ListBucket permission from MinIO bucket policy
This commit is contained in:
@@ -165,12 +165,9 @@ class MinioStorage(Storage):
|
|||||||
'"Version":"2012-10-17",'
|
'"Version":"2012-10-17",'
|
||||||
'"Statement":['
|
'"Statement":['
|
||||||
'{"Effect":"Allow","Principal":{"AWS":["*"]},'
|
'{"Effect":"Allow","Principal":{"AWS":["*"]},'
|
||||||
'"Action":["s3:GetBucketLocation","s3:ListBucket"],'
|
|
||||||
'"Resource":["arn:aws:s3:::%s"]},'
|
|
||||||
'{"Effect":"Allow","Principal":{"AWS":["*"]},'
|
|
||||||
'"Action":["s3:GetObject"],'
|
'"Action":["s3:GetObject"],'
|
||||||
'"Resource":["arn:aws:s3:::%s/*"]}'
|
'"Resource":["arn:aws:s3:::%s/*"]}'
|
||||||
"]}" % (bucket_name, bucket_name)
|
"]}" % (bucket_name)
|
||||||
)
|
)
|
||||||
client.set_bucket_policy(bucket_name, policy)
|
client.set_bucket_policy(bucket_name, policy)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user