DeployOptions
- class aws_cdk.cli_lib_alpha.DeployOptions(*, asset_metadata=None, ca_bundle_path=None, color=None, context=None, debug=None, ec2_creds=None, ignore_errors=None, json=None, lookups=None, notices=None, path_metadata=None, profile=None, proxy=None, role_arn=None, stacks=None, staging=None, strict=None, trace=None, verbose=None, version_reporting=None, asset_parallelism=None, asset_prebuild=None, change_set_name=None, ci=None, concurrency=None, exclusively=None, execute=None, force=None, hotswap=None, notification_arns=None, outputs_file=None, parameters=None, progress=None, require_approval=None, reuse_assets=None, rollback=None, toolkit_stack_name=None, use_previous_parameters=None)
Bases:
SharedOptions
(experimental) Options to use with cdk deploy.
- Parameters:
asset_metadata (
Optional
[bool
]) – (experimental) Include “aws:asset:*” CloudFormation metadata for resources that use assets. Default: trueca_bundle_path (
Optional
[str
]) – (experimental) Path to CA certificate to use when validating HTTPS requests. Default: - read from AWS_CA_BUNDLE environment variablecolor (
Optional
[bool
]) – (experimental) Show colors and other style from console output. Default: -true
unless the environment variableNO_COLOR
is setcontext (
Optional
[Mapping
[str
,str
]]) – (experimental) Additional context. Default: - no additional contextdebug (
Optional
[bool
]) – (experimental) enable emission of additional debugging information, such as creation stack traces of tokens. Default: falseec2_creds (
Optional
[bool
]) – (experimental) Force trying to fetch EC2 instance credentials. Default: - guess EC2 instance statusignore_errors (
Optional
[bool
]) – (experimental) Ignores synthesis errors, which will likely produce an invalid output. Default: falsejson (
Optional
[bool
]) – (experimental) Use JSON output instead of YAML when templates are printed to STDOUT. Default: falselookups (
Optional
[bool
]) – (experimental) Perform context lookups. Synthesis fails if this is disabled and context lookups need to be performed Default: truenotices (
Optional
[bool
]) – (experimental) Show relevant notices. Default: truepath_metadata (
Optional
[bool
]) – (experimental) Include “aws:cdk:path” CloudFormation metadata for each resource. Default: trueprofile (
Optional
[str
]) – (experimental) Use the indicated AWS profile as the default environment. Default: - no profile is usedproxy (
Optional
[str
]) – (experimental) Use the indicated proxy. Will read from HTTPS_PROXY environment if specified Default: - no proxyrole_arn (
Optional
[str
]) – (experimental) Role to pass to CloudFormation for deployment. Default: - use the bootstrap cfn-exec rolestacks (
Optional
[Sequence
[str
]]) – (experimental) List of stacks to deploy. Default: - all stacksstaging (
Optional
[bool
]) – (experimental) Copy assets to the output directory. Needed for local debugging the source files with SAM CLI Default: falsestrict (
Optional
[bool
]) – (experimental) Do not construct stacks with warnings. Default: falsetrace (
Optional
[bool
]) – (experimental) Print trace for stack warnings. Default: falseverbose (
Optional
[bool
]) – (experimental) show debug logs. Default: falseversion_reporting (
Optional
[bool
]) – (experimental) Include “AWS::CDK::Metadata” resource in synthesized templates. Default: trueasset_parallelism (
Optional
[bool
]) – (experimental) Whether to build/publish assets in parallel. Default: falseasset_prebuild (
Optional
[bool
]) – (experimental) Whether to build all assets before deploying the first stack (useful for failing Docker builds). Default: truechange_set_name (
Optional
[str
]) – (experimental) Optional name to use for the CloudFormation change set. If not provided, a name will be generated automatically. Default: - auto generate a nameci (
Optional
[bool
]) – (experimental) Whether we are on a CI system. Default: -false
unless the environment variableCI
is setconcurrency (
Union
[int
,float
,None
]) – (experimental) Maximum number of simultaneous deployments (dependency permitting) to execute. Default: 1exclusively (
Optional
[bool
]) – (experimental) Only perform action on the given stack. Default: falseexecute (
Optional
[bool
]) – (experimental) Whether to execute the ChangeSet Not providingexecute
parameter will result in execution of ChangeSet. Default: trueforce (
Optional
[bool
]) – (experimental) Always deploy, even if templates are identical. Default: falsehotswap (
Optional
[HotswapMode
]) –notification_arns (
Optional
[Sequence
[str
]]) – (experimental) ARNs of SNS topics that CloudFormation will notify with stack related events. Default: - no notificationsoutputs_file (
Optional
[str
]) – (experimental) Path to file where stack outputs will be written after a successful deploy as JSON. Default: - Outputs are not written to any fileparameters (
Optional
[Mapping
[str
,str
]]) – (experimental) Additional parameters for CloudFormation at deploy time. Default: {}progress (
Optional
[StackActivityProgress
]) – (experimental) Display mode for stack activity events. The default in the CLI is StackActivityProgress.BAR. But since this is an API it makes more sense to set the default to StackActivityProgress.EVENTS Default: StackActivityProgress.EVENTSrequire_approval (
Optional
[RequireApproval
]) – (experimental) What kind of security changes require approval. Default: RequireApproval.Neverreuse_assets (
Optional
[Sequence
[str
]]) – (experimental) Reuse the assets with the given asset IDs. Default: - do not reuse assetsrollback (
Optional
[bool
]) – (experimental) Rollback failed deployments. Default: truetoolkit_stack_name (
Optional
[str
]) – (experimental) Name of the toolkit stack to use/deploy. Default: CDKToolkituse_previous_parameters (
Optional
[bool
]) – (experimental) Use previous values for unspecified parameters. If not set, all parameters must be specified for every deployment. Default: true
- Stability:
experimental
- ExampleMetadata:
infused
Example:
# await this asynchronous method call using a language feature cli.deploy( stacks=["MyTestStack"] )
Attributes
- asset_metadata
*” CloudFormation metadata for resources that use assets.
- Default:
true
- Stability:
experimental
- Type:
(experimental) Include “aws
- Type:
asset
- asset_parallelism
(experimental) Whether to build/publish assets in parallel.
- Default:
false
- Stability:
experimental
- asset_prebuild
(experimental) Whether to build all assets before deploying the first stack (useful for failing Docker builds).
- Default:
true
- Stability:
experimental
- ca_bundle_path
(experimental) Path to CA certificate to use when validating HTTPS requests.
- Default:
read from AWS_CA_BUNDLE environment variable
- Stability:
experimental
- change_set_name
(experimental) Optional name to use for the CloudFormation change set.
If not provided, a name will be generated automatically.
- Default:
auto generate a name
- Stability:
experimental
- ci
(experimental) Whether we are on a CI system.
- Default:
false
unless the environment variableCI
is set
- Stability:
experimental
- color
(experimental) Show colors and other style from console output.
- Default:
true
unless the environment variableNO_COLOR
is set
- Stability:
experimental
- concurrency
(experimental) Maximum number of simultaneous deployments (dependency permitting) to execute.
- Default:
1
- Stability:
experimental
- context
(experimental) Additional context.
- Default:
no additional context
- Stability:
experimental
- debug
(experimental) enable emission of additional debugging information, such as creation stack traces of tokens.
- Default:
false
- Stability:
experimental
- ec2_creds
(experimental) Force trying to fetch EC2 instance credentials.
- Default:
guess EC2 instance status
- Stability:
experimental
- exclusively
(experimental) Only perform action on the given stack.
- Default:
false
- Stability:
experimental
- execute
(experimental) Whether to execute the ChangeSet Not providing
execute
parameter will result in execution of ChangeSet.- Default:
true
- Stability:
experimental
- force
(experimental) Always deploy, even if templates are identical.
- Default:
false
- Stability:
experimental
- hotswap
experimental
- Type:
stability
- ignore_errors
(experimental) Ignores synthesis errors, which will likely produce an invalid output.
- Default:
false
- Stability:
experimental
- json
(experimental) Use JSON output instead of YAML when templates are printed to STDOUT.
- Default:
false
- Stability:
experimental
- lookups
(experimental) Perform context lookups.
Synthesis fails if this is disabled and context lookups need to be performed
- Default:
true
- Stability:
experimental
- notices
(experimental) Show relevant notices.
- Default:
true
- Stability:
experimental
- notification_arns
(experimental) ARNs of SNS topics that CloudFormation will notify with stack related events.
- Default:
no notifications
- Stability:
experimental
- outputs_file
(experimental) Path to file where stack outputs will be written after a successful deploy as JSON.
- Default:
Outputs are not written to any file
- Stability:
experimental
- parameters
(experimental) Additional parameters for CloudFormation at deploy time.
- Default:
{}
- Stability:
experimental
- path_metadata
path” CloudFormation metadata for each resource.
- Default:
true
- Stability:
experimental
- Type:
(experimental) Include “aws
- Type:
cdk
- profile
(experimental) Use the indicated AWS profile as the default environment.
- Default:
no profile is used
- Stability:
experimental
- progress
(experimental) Display mode for stack activity events.
The default in the CLI is StackActivityProgress.BAR. But since this is an API it makes more sense to set the default to StackActivityProgress.EVENTS
- Default:
StackActivityProgress.EVENTS
- Stability:
experimental
- proxy
(experimental) Use the indicated proxy.
Will read from HTTPS_PROXY environment if specified
- Default:
no proxy
- Stability:
experimental
- require_approval
(experimental) What kind of security changes require approval.
- Default:
RequireApproval.Never
- Stability:
experimental
- reuse_assets
(experimental) Reuse the assets with the given asset IDs.
- Default:
do not reuse assets
- Stability:
experimental
- role_arn
(experimental) Role to pass to CloudFormation for deployment.
- Default:
use the bootstrap cfn-exec role
- Stability:
experimental
- rollback
(experimental) Rollback failed deployments.
- Default:
true
- Stability:
experimental
- stacks
(experimental) List of stacks to deploy.
- Default:
all stacks
- Stability:
experimental
- staging
(experimental) Copy assets to the output directory.
Needed for local debugging the source files with SAM CLI
- Default:
false
- Stability:
experimental
- strict
(experimental) Do not construct stacks with warnings.
- Default:
false
- Stability:
experimental
- toolkit_stack_name
(experimental) Name of the toolkit stack to use/deploy.
- Default:
CDKToolkit
- Stability:
experimental
- trace
(experimental) Print trace for stack warnings.
- Default:
false
- Stability:
experimental
- use_previous_parameters
(experimental) Use previous values for unspecified parameters.
If not set, all parameters must be specified for every deployment.
- Default:
true
- Stability:
experimental
- verbose
(experimental) show debug logs.
- Default:
false
- Stability:
experimental
- version_reporting
(experimental) Include “AWS::CDK::Metadata” resource in synthesized templates.
- Default:
true
- Stability:
experimental