s3: reenable tenanted bucket policy test#577
Conversation
|
the existing test case
this new test case |
s3tests_boto3/functional/__init__.py
Outdated
| def get_tenant_name(): | ||
| s = config.tenant_display_name | ||
| return s[:s.index('$')] |
There was a problem hiding this comment.
this works for the default value from s3tests.conf.SAMPLE:
[s3 tenant]
# tenant display_name set in vstart.sh
display_name = testx$tenanteduserbut fails in teuthology where qa/tasks/s3tests.py sets display_name to Mr.testx$tenanteduser. rgw sees these requests as:
REQUEST_URI=/Mr.testx%3Atest-fak34zuywqcog5fhyh4e22bc-475?encoding-type=url
and rejects it with 400 InvalidTenantName because of the . in Mr.testx
There was a problem hiding this comment.
since we need the tenant name for this test new case, i added a new tenant variable to the [s3 tenant] config section. i added a new commit to ceph/ceph#59169 that configures this in teuthology
the before-call hook url-encodes the ':' part of tenanted bucket names to resolve SignatureDoesNotMatch errors removed the list-v2 version of the test since it isn't relevant to bucket policy test coverage add a new test case that creates the bucket under the tenanted user, then uses the main client to access it Signed-off-by: Casey Bodley <[email protected]>
2abbf69 to
2e41494
Compare
|
cherry-picked to ceph-master |
the before-call hook url-encodes the ':' part of tenanted bucket names to resolve SignatureDoesNotMatch errors
removed the list-v2 version of the test since it isn't relevant to bucket policy test coverage
add a new test case that creates the bucket under the tenanted user, then uses the main client to access it