**kwargs
)
+
def build_initial_config(ctx, config):
cluster_name = config['cluster']
return conf
+
def update_archive_setting(ctx, key, value):
"""
Add logs directory to job's info log file
info_yaml['archive'] = {key: value}
yaml.safe_dump(info_yaml, info_file, default_flow_style=False)
+
@contextlib.contextmanager
def normalize_hostnames(ctx):
"""
finally:
pass
+
@contextlib.contextmanager
def download_cephadm(ctx, config, ref):
cluster_name = config['cluster']
],
)
+
@contextlib.contextmanager
def ceph_log(ctx, config):
cluster_name = config['cluster']
except ReadError:
pass
+
@contextlib.contextmanager
def ceph_crash(ctx, config):
"""
except ReadError:
pass
+
@contextlib.contextmanager
def ceph_bootstrap(ctx, config):
"""
'/etc/ceph/{}.client.admin.keyring'.format(cluster_name),
])
+
@contextlib.contextmanager
def ceph_mons(ctx, config):
"""
finally:
pass
+
@contextlib.contextmanager
def ceph_mgrs(ctx, config):
"""
finally:
pass
+
@contextlib.contextmanager
def ceph_osds(ctx, config):
"""
finally:
pass
+
@contextlib.contextmanager
def ceph_mdss(ctx, config):
"""
yield
+
@contextlib.contextmanager
def ceph_monitoring(daemon_type, ctx, config):
"""
yield
+
@contextlib.contextmanager
def ceph_rgw(ctx, config):
"""
yield
+
@contextlib.contextmanager
def ceph_clients(ctx, config):
cluster_name = config['cluster']
remote.sudo_write_file(client_keyring, keyring, mode='0644')
yield
+
@contextlib.contextmanager
def ceph_initial():
try:
finally:
log.info('Teardown complete')
+
## public methods
@contextlib.contextmanager
def stop(ctx, config):
yield
+
def shell(ctx, config):
"""
Execute (shell) commands
for option, value in saved_options.items():
manager.inject_args(type_, id_, option, value)
+
@contextlib.contextmanager
def restart(ctx, config):
"""
ctx.managers[cluster].wait_for_all_osds_up()
yield
+
@contextlib.contextmanager
def distribute_config_and_admin_keyring(ctx, config):
"""
'/etc/ceph/{}.client.admin.keyring'.format(cluster_name),
])
+
@contextlib.contextmanager
def crush_setup(ctx, config):
cluster_name = config['cluster']
args=['ceph', 'osd', 'crush', 'tunables', profile])
yield
+
@contextlib.contextmanager
def create_rbd_pool(ctx, config):
if config.get('create_rbd_pool', False):
])
yield
+
@contextlib.contextmanager
def _bypass():
yield
+
@contextlib.contextmanager
def initialize_config(ctx, config):
cluster_name = config['cluster']
ctx.ceph[cluster_name].first_mgr = first_mgr
yield
+
@contextlib.contextmanager
def task(ctx, config):
"""