ruby - AWS S3 and CEPH / Rados Bucket permission inheritance -
i'm having issues creating publicly readable bucket. i'm working in ceph / rados store using amazon aws-sdk v 1.60.2
i created bucket similar many different tutorials with
s3.buckets.create('bucketname', :acl => :public_read)
i uploaded number of files s3.buckets['bucketname']
when go in , @ specific permissions bucket , it's internal objects bucket see has read permissions granted allusers group full_control set user created bucket with. objects not inherit anonymous read permissions. need objects in bucket readable anonymously.
as note see these permissions when run s3.buckets['bucketname'].acl
. when try run s3.buckets['bucketname'].policy
following error makes no sense:
/var/lib/gems/1.9.1/gems/json-1.8.3/lib/json/common.rb:155:in `parse': 757: unexpected token @ '<?xml version="1.0" encoding="utf-8"?><listbucketresult xmlns="http://s3.amazonaws.com/doc/2006-03-01/"><name>erik.test</name><prefix></prefix><marker></marker><maxkeys>1000</maxkeys><istruncated>false</istruncated></listbucketresult>' (json::parsererror) /var/lib/gems/1.9.1/gems/json-1.8.3/lib/json/common.rb:155:in `parse' /var/lib/gems/1.9.1/gems/aws-sdk-v1-1.60.2/lib/aws/core/policy.rb:146:in `from_json' /var/lib/gems/1.9.1/gems/aws-sdk-v1-1.60.2/lib/aws/s3/bucket.rb:621:in `policy' test.rb:20:in `<main>'
the above error looks aws-sdk calling json parser on xml string shouldn't happening.
i cannot upload objects explicit permissions because project have bosh uploading store automatically.
unfortunately policies inherited, while possible read list of objects in bucket, stands anonymous read permission doesn't continue items uploaded.
Comments
Post a Comment