StackDeployment
- class aws_cdk.pipelines.StackDeployment(*args: Any, **kwargs)
Bases:
objectDeployment of a single Stack.
You don’t need to instantiate this class – it will be automatically instantiated as necessary when you add a
Stageto a pipeline.- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. import aws_cdk.cx_api as cx_api import aws_cdk.pipelines as pipelines # cloud_formation_stack_artifact: cx_api.CloudFormationStackArtifact stack_deployment = pipelines.StackDeployment.from_artifact(cloud_formation_stack_artifact)
Methods
- add_stack_dependency(stack_deployment)
Add a dependency on another stack.
- Parameters:
stack_deployment (
StackDeployment)- Return type:
None
- add_stack_steps(pre, change_set, post)
Adds steps to each phase of the stack.
Attributes
- absolute_template_path
Template path on disk to CloudAssembly.
- account
Account where the stack should be deployed.
- Default:
Pipeline account
- assets
Assets referenced by this stack.
- assume_role_arn
Role to assume before deploying this stack.
- Default:
Don’t assume any role
- change_set
Steps that take place after stack is prepared but before stack deploys.
Your pipeline engine may not disable
prepareStep.
- construct_path
Construct path for this stack.
- execution_role_arn
Execution role to pass to CloudFormation.
- Default:
No execution role
- post
Steps to execute after stack deploys.
- pre
Steps that take place before stack is prepared.
If your pipeline engine disables ‘prepareStep’, then this will happen before stack deploys
- region
Region where the stack should be deployed.
- Default:
Pipeline region
- stack_artifact_id
Artifact ID for this stack.
- stack_dependencies
Other stacks this stack depends on.
- stack_name
Name for this stack.
- tags
Tags to apply to the stack.
- template_asset
The asset that represents the CloudFormation template for this stack.
- template_url
The S3 URL which points to the template asset location in the publishing bucket.
This is
undefinedif the stack template is not published. Use theDefaultStackSynthesizerto ensure it is.Example value:
https://bucket.s3.amazonaws.com/object/key
Static Methods
- classmethod from_artifact(stack_artifact)
Build a
StackDeploymentfrom a Stack Artifact in a Cloud Assembly.- Parameters:
stack_artifact (
CloudFormationStackArtifact)- Return type: