BranchProps
- class aws_cdk.aws_amplify_alpha.BranchProps(*, asset=None, auto_build=None, basic_auth=None, branch_name=None, build_spec=None, description=None, environment_variables=None, performance_mode=None, pull_request_environment_name=None, pull_request_preview=None, stage=None, app)
Bases:
BranchOptions
(experimental) Properties for a Branch.
- Parameters:
asset (
Optional
[Asset
]) – (experimental) Asset for deployment. The Amplify app must not have a sourceCodeProvider configured as this resource uses Amplify’s startDeployment API to initiate and deploy a S3 asset onto the App. Default: - no assetauto_build (
Optional
[bool
]) – (experimental) Whether to enable auto building for the branch. Default: truebasic_auth (
Optional
[BasicAuth
]) – (experimental) The Basic Auth configuration. Use this to set password protection for the branch Default: - no password protectionbranch_name (
Optional
[str
]) – (experimental) The name of the branch. Default: - the construct’s idbuild_spec (
Optional
[BuildSpec
]) – (experimental) BuildSpec for the branch. Default: - no build specdescription (
Optional
[str
]) – (experimental) A description for the branch. Default: - no descriptionenvironment_variables (
Optional
[Mapping
[str
,str
]]) – (experimental) Environment variables for the branch. All environment variables that you add are encrypted to prevent rogue access so you can use them to store secret information. Default: - application environment variablesperformance_mode (
Optional
[bool
]) – (experimental) Enables performance mode for the branch. Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out. Default: falsepull_request_environment_name (
Optional
[str
]) – (experimental) The dedicated backend environment for the pull request previews. Default: - automatically provision a temporary backendpull_request_preview (
Optional
[bool
]) – (experimental) Whether to enable pull request preview for the branch. Default: truestage (
Optional
[str
]) – (experimental) Stage for the branch. Default: - no stageapp (
IApp
) – (experimental) The application within which the branch must be created.
- Stability:
experimental
- 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.aws_amplify_alpha as amplify_alpha from aws_cdk import aws_codebuild as codebuild from aws_cdk import aws_s3_assets as s3_assets # app: amplify_alpha.App # asset: s3_assets.Asset # basic_auth: amplify_alpha.BasicAuth # build_spec: codebuild.BuildSpec branch_props = amplify_alpha.BranchProps( app=app, # the properties below are optional asset=asset, auto_build=False, basic_auth=basic_auth, branch_name="branchName", build_spec=build_spec, description="description", environment_variables={ "environment_variables_key": "environmentVariables" }, performance_mode=False, pull_request_environment_name="pullRequestEnvironmentName", pull_request_preview=False, stage="stage" )
Attributes
- app
(experimental) The application within which the branch must be created.
- Stability:
experimental
- asset
(experimental) Asset for deployment.
The Amplify app must not have a sourceCodeProvider configured as this resource uses Amplify’s startDeployment API to initiate and deploy a S3 asset onto the App.
- Default:
no asset
- Stability:
experimental
- auto_build
(experimental) Whether to enable auto building for the branch.
- Default:
true
- Stability:
experimental
- basic_auth
(experimental) The Basic Auth configuration.
Use this to set password protection for the branch
- Default:
no password protection
- Stability:
experimental
- branch_name
(experimental) The name of the branch.
- Default:
the construct’s id
- Stability:
experimental
- build_spec
(experimental) BuildSpec for the branch.
- Default:
no build spec
- See:
https://docs.aws.amazon.com/amplify/latest/userguide/build-settings.html
- Stability:
experimental
- description
(experimental) A description for the branch.
- Default:
no description
- Stability:
experimental
- environment_variables
(experimental) Environment variables for the branch.
All environment variables that you add are encrypted to prevent rogue access so you can use them to store secret information.
- Default:
application environment variables
- Stability:
experimental
- performance_mode
(experimental) Enables performance mode for the branch.
Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out.
- Default:
false
- Stability:
experimental
- pull_request_environment_name
(experimental) The dedicated backend environment for the pull request previews.
- Default:
automatically provision a temporary backend
- Stability:
experimental
- pull_request_preview
(experimental) Whether to enable pull request preview for the branch.
- Default:
true
- Stability:
experimental
- stage
(experimental) Stage for the branch.
- Default:
no stage
- Stability:
experimental