Tidyup docstring and method name
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
from zaza.openstack.utilities import (
|
||||
cli as cli_utils,
|
||||
openstack as openstack_utils,
|
||||
openstack_upgrade as upgrade_utils,
|
||||
)
|
||||
|
||||
|
||||
applications = []
|
||||
for group in ['Core Identity', 'Storage', 'Control Plane', 'Compute']:
|
||||
applications.extend(upgrade_utils.SERVICE_GROUPS[group])
|
||||
print(applications)
|
||||
@@ -55,7 +55,7 @@ def basic_setup_and_unseal(cacert=None):
|
||||
|
||||
def mojo_unseal_by_unit():
|
||||
"""Unseal any units reported as sealed using mojo cacert."""
|
||||
cacert = zaza.openstack.utilities.generic.get_mojo_cacert()
|
||||
cacert = zaza.openstack.utilities.generic.get_mojo_cacert_path()
|
||||
vault_creds = vault_utils.get_credentails()
|
||||
for client in vault_utils.get_clients(cacert=cacert):
|
||||
if client.hvac_client.is_sealed():
|
||||
|
||||
@@ -852,12 +852,13 @@ def systemctl(unit, service, command="restart"):
|
||||
"{} of {} on {} failed".format(command, service, unit.entity_id))
|
||||
|
||||
|
||||
def get_mojo_cacert():
|
||||
def get_mojo_cacert_path():
|
||||
"""Retrieve cacert from Mojo storage location.
|
||||
|
||||
:returns: Pathh to cacert
|
||||
:returns: Path to cacert
|
||||
:rtype: str
|
||||
:raises: zaza_exceptions.CACERTNotFound
|
||||
:raises: :class:`zaza_exceptions.CACERTNotfound`
|
||||
"""
|
||||
try:
|
||||
cert_dir = os.environ['MOJO_LOCAL_DIR']
|
||||
|
||||
Reference in New Issue
Block a user