How to use the sceptre.config_reader.ConfigReader function in sceptre

To help you get started, we’ve selected a few sceptre examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Sceptre / sceptre / sceptre / cli.py View on Github external
def _get_env(ctx, environment):
    """
    Initialises and returns a sceptre.environment.Environment().

    :param sceptre_dir: The absolute path to the Sceptre directory.
    :type project dir: str
    :param environment: The name of the environment.
    :type environment: str
    :returns: An Environment.
    :rtype: sceptre.environment.Environment
    """
    config_reader = ConfigReader(
        ctx.obj["sceptre_dir"], ctx.obj["templating_vars"]
    )
    return config_reader.construct_environment(environment)
github Sceptre / sceptre / sceptre / cli.py View on Github external
def _get_stack(ctx, environment, stack):
    """
    Initialises and returns a sceptre.stack.Stack().

    :param sceptre_dir: The absolute path to the Sceptre directory.
    :type project dir: str
    :param environment: The name of the environment.
    :type environment: str
    :param stack: The name of the stack.
    :type stack: str
    :returns: A Stack.
    :rtype: sceptre.stack.Stack
    """
    path = os.path.join(environment, stack) + ".yaml"
    config_reader = ConfigReader(
        ctx.obj["sceptre_dir"], ctx.obj["templating_vars"]
    )
    return config_reader.construct_stack(path)