コード例 #1
0
def main():
    logger.init_execution_trace()
    try:
        ScarCLI().parse_arguments()
        logger.end_execution_trace()
    except Exception as excp:
        print(excp)
        logger.exception(excp)
        logger.end_execution_trace_with_errors()
コード例 #2
0
ファイル: scarcli.py プロジェクト: thenewguy/scar
def main():
    logger.init_execution_trace()
    try:
        func_call = parse_arguments()
        # Default provider
        # If more providers, analyze the arguments and build the required one
        AWS(func_call)
        logger.end_execution_trace()
    except Exception as excp:
        print(excp)
        logger.exception(excp)
        logger.end_execution_trace_with_errors()
コード例 #3
0
def main():
    logger.init_execution_trace()
    try:
        func_call = parse_arguments()
        # Default provider
        # If more providers, analyze the arguments and build the required one
        AWS(func_call)
        # Build the OSCAR controller only with 'init', 'rm' and 'ls' commands
        if func_call in ['init', 'rm', 'ls']:
            OSCAR(func_call)
        logger.end_execution_trace()
    except Exception as excp:
        print(excp)
        logger.exception(excp)
        logger.end_execution_trace_with_errors()
コード例 #4
0
ファイル: utils.py プロジェクト: grycap/scar
 def finish_scar_execution() -> None:
     """Finishes the program execution."""
     logger.end_execution_trace()
     sys.exit(0)