huaweicloud / huaweicloud-sdk-python-obs

Apache License 2.0
75 stars 41 forks source link

Unable to set ACL to allow logging agent to write to a bucket on OBS #16

Open davidboweninrupt opened 2 years ago

davidboweninrupt commented 2 years ago

I believe 'log-delivery-write' should be in OBS_ALLOWED_ACL_CONTROL so we can give the logging agent permissions when using OBS.

I have added this locally and it seems to work very well.

Guillaume Le Blanc of Orange Business Cloud suggested this would be the right place get the change made.

Without it being in there the aclControl header doesn't get added and we get this error when calling setBucketAcl like this:

setBucketAcl(bucket_name, aclControl=HeadPermission.LOG_DELIVERY_WRITE)

This content appears in the response: <MissingHeaderName>x-obs-acl</MissingHeaderName>

liqiuqiu111 commented 9 months ago

https://support.huaweicloud.com/sdk-python-devg-obs/obs_22_0814.html#section5 设置bucketACL参考此文档

davidboweninrupt commented 9 months ago

Thanks for the link @liqiuqiu111 .

I'm not sure what help that offers because it seems LOG_DELIVERY_WRITE is not included in the list of choices.

As mentioned, I'd like it to be added to the list of aclControl values that can be used.