aws_ddk_core.base.BaseStack¶
- class aws_ddk_core.base.BaseStack(*args: Any, **kwargs)¶
Base Stack to inherit from.
Includes configurable termination protection, synthesizer, permissions boundary and tags.
- __init__(scope: constructs.Construct, id: str, environment_id: str, termination_protection: Optional[bool] = None, permissions_boundary_arn: Optional[str] = None, synthesizer: Optional[aws_cdk.DefaultStackSynthesizer] = None, **kwargs: Any) None ¶
Create a stack.
Includes termination protection settings, multi-level (application, environment, and stack-level) tags, and permissions boundary.
- Parameters
scope (Construct) – Scope within which this construct is defined
id (str) – Identifier of the stack
environment_id (str) – Identifier of the environment
termination_protection (Optional[bool]) – Stack termination protection
permissions_boundary_arn (Optional[str]) – ARN of the permissions boundary managed policy
synthesizer (Optional[DefaultStackSynthesizer]) – CDK synthesizer configuration https://docs.aws.amazon.com/cdk/v2/guide/bootstrapping.html#bootstrapping-synthesizers
kwargs (Any) – Additional arguments
Methods
__init__
(scope, id, environment_id[, ...])Create a stack.
add_dependency
(target[, reason])Add a dependency between this stack and another stack.
add_transform
(transform)Add a Transform to this stack.
export_value
(exported_value, *[, name])Create a CloudFormation Export for a value.
format_arn
(*, resource, service[, account, ...])Creates an ARN from components.
get_logical_id
(element)Allocates a stack-unique CloudFormation-compatible logical identity for a specific resource.
is_construct
(x)(deprecated) Checks if
x
is a construct.is_stack
(x)Return whether the given object is a Stack.
of
(construct)Looks up the first stack scope in which
construct
is defined.regional_fact
(fact_name[, default_value])Look up a fact value for the given fact for the region of this stack.
rename_logical_id
(old_id, new_id)Rename a generated logical identities.
report_missing_context_key
(*, key, props, ...)Indicate that a context key was expected.
resolve
(obj)Resolve a tokenized value in the context of the current stack.
split_arn
(arn, arn_format)Splits the provided ARN into its components.
to_json_string
(obj[, space])Convert an object, potentially containing tokens, to a JSON string.
to_string
()Returns a string representation of this construct.
Attributes
account
The AWS account into which this stack will be deployed.
artifact_id
The ID of the cloud assembly artifact for this stack.
availability_zones
Returns the list of AZs that are available in the AWS environment (account/region) associated with this stack.
dependencies
Return the stacks this stack depends on.
environment
The environment coordinates in which this stack is deployed.
nested
Indicates if this is a nested stack, in which case
parentStack
will include a reference to it's parent.nested_stack_parent
If this is a nested stack, returns it's parent stack.
nested_stack_resource
If this is a nested stack, this represents its
AWS::CloudFormation::Stack
resource.node
The tree node.
notification_arns
Returns the list of notification Amazon Resource Names (ARNs) for the current stack.
partition
The partition in which this stack is defined.
region
The AWS region into which this stack will be deployed (e.g.
stack_id
The ID of the stack.
stack_name
The concrete CloudFormation physical stack name.
synthesizer
Synthesis method for this stack.
tags
Tags to be applied to the stack.
template_file
The name of the CloudFormation template file emitted to the output directory during synthesis.
template_options
Options for CloudFormation template (like version, transform, description).
termination_protection
Whether termination protection is enabled for this stack.
url_suffix
The Amazon domain suffix for the region in which this stack is defined.