in blueprints/third-party-solutions/openshift/prepare.py [0:0]
def cli(ctx=None, credentials=None, tfdir=None, tfvars=None, verbosity='INFO'):
'Program entry point.'
logging.basicConfig(level=getattr(logging, verbosity))
logging.info('program starting')
ctx.ensure_object(dict)
try:
tfvars_ = _parse_tfvars(tfvars, tfdir)
ctx.obj['tfvars'] = tfvars_
ctx.obj['paths'] = _check_convert_paths(**tfvars_['fs_paths'])
except Error as e:
print(f'Error: {e.args[0]}')
sys.exit(1)
if ctx.invoked_subcommand is None:
commands = [
'install-config', 'manifests', 'manifests-edit', 'ignition-configs'
]
else:
commands = [ctx.invoked_subcommand]
try:
for c in commands:
ctx.invoke(ctx.command.commands[c])
except Error as e:
print(e)
sys.exit(1)
sys.exit(0)