Remove the duplicated swift ring files check

1. the swift ring files check is done in swift prechecks role in
kolla-ansible[1], no need to double check in kolla-cli.

[1]: https://github.com/openstack/kolla-ansible/blob/master/ansible/roles/swift/tasks/precheck.yml#L100

Change-Id: Ia316ee788b1847f8da08d3a3b3693761f37c1125
This commit is contained in:
jacky06 2019-07-29 22:34:15 +08:00
parent 6b03977fd7
commit 50ffbe5188
1 changed files with 0 additions and 20 deletions

View File

@ -230,26 +230,6 @@ def _run_deploy_rules(playbook):
'have no associated hosts')
.format(groups=failed_groups, services=failed_services))
# check that ring files are in /etc/kolla/config/swift if
# swift is enabled
expected_files = ['account.ring.gz',
'container.ring.gz',
'object.ring.gz']
is_swift_enabled = _is_service_enabled('swift', inventory, properties)
if is_swift_enabled:
path_pre = os.path.join(get_kolla_etc(), 'config', 'swift')
for expected_file in expected_files:
path = os.path.join(path_pre, expected_file)
if not os.path.isfile(path):
msg = u._(
'Deploy failed. '
'Swift is enabled but ring buffers have '
'not yet been set up. Please see the '
'documentation for swift configuration '
'instructions.')
raise InvalidConfiguration(msg)
def _is_service_enabled(servicename, inventory, properties):
service = inventory.get_service(servicename)