Merge pull request #28532 from cbodley/wip-40304

qa/rgw: skip swift tests on rhel 7.6+
This commit is contained in:
Yuri Weinstein 2019-06-14 08:16:32 -07:00 committed by GitHub
commit 2b3719264c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,6 +8,7 @@ import contextlib
import logging
import os
from packaging import version
from teuthology import misc as teuthology
from teuthology import contextutil
from teuthology.config import config as teuth_config
@ -231,15 +232,22 @@ def task(ctx, config):
config = all_clients
if isinstance(config, list):
config = dict.fromkeys(config)
clients = config.keys()
log.info('clients={c}'.format(c=clients))
testswift_conf = {}
for client in clients:
clients = []
for client in config.keys():
endpoint = ctx.rgw.role_endpoints.get(client)
assert endpoint, 'swift: no rgw endpoint for {}'.format(client)
# http://tracker.ceph.com/issues/40304 can't bootstrap on rhel 7.6+
(remote,) = ctx.cluster.only(client).remotes.keys()
os_version = version.parse(remote.os.version):
if remote.os.type == 'rhel' and os_version >= version.Version('7.6'):
log.warning('Swift tests cannot run on rhel 7.6+, skipping client {client}'.format(client))
continue
clients.append(client)
testswift_conf[client] = ConfigObj(
indent_type='',
infile={
@ -252,6 +260,7 @@ def task(ctx, config):
}
)
log.info('clients={c}'.format(c=config.keys()))
with contextutil.nested(
lambda: download(ctx=ctx, config=config),
lambda: create_users(ctx=ctx, config=dict(