Merge pull request #946 from ceph/wip-rgw-fix-teu-bucket-policy

rgw: policy acl format should be xml
This commit is contained in:
Casey Bodley 2016-04-08 17:03:30 -04:00
commit 9d81246e8d
2 changed files with 5 additions and 4 deletions

View File

@ -931,7 +931,7 @@ def task(ctx, config):
(err, out) = rgwadmin(ctx, client,
['policy', '--bucket', bucket.name, '--object', key.key],
check_status=True)
check_status=True, format='xml')
acl = get_acl(key)
@ -942,7 +942,7 @@ def task(ctx, config):
(err, out) = rgwadmin(ctx, client,
['policy', '--bucket', bucket.name, '--object', key.key],
check_status=True)
check_status=True, format='xml')
acl = get_acl(key)

View File

@ -15,7 +15,8 @@ def multi_region_enabled(ctx):
# use that as an indicator that we're testing multi-region sync
return 'radosgw_agent' in ctx
def rgwadmin(ctx, client, cmd, stdin=StringIO(), check_status=False):
def rgwadmin(ctx, client, cmd, stdin=StringIO(), check_status=False,
format='json'):
log.info('rgwadmin: {client} : {cmd}'.format(client=client,cmd=cmd))
testdir = teuthology.get_testdir(ctx)
pre = [
@ -24,7 +25,7 @@ def rgwadmin(ctx, client, cmd, stdin=StringIO(), check_status=False):
'{tdir}/archive/coverage'.format(tdir=testdir),
'radosgw-admin'.format(tdir=testdir),
'--log-to-stderr',
'--format', 'json',
'--format', format,
'-n', client,
]
pre.extend(cmd)