interface AutoBranchCreation
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Amplify.Alpha.AutoBranchCreation |
Go | github.com/aws/aws-cdk-go/awscdkamplifyalpha/v2#AutoBranchCreation |
Java | software.amazon.awscdk.services.amplify.alpha.AutoBranchCreation |
Python | aws_cdk.aws_amplify_alpha.AutoBranchCreation |
TypeScript (source) | @aws-cdk/aws-amplify-alpha ยป AutoBranchCreation |
Auto branch creation configuration.
Example
const amplifyApp = new amplify.App(this, 'MyApp', {
sourceCodeProvider: new amplify.GitHubSourceCodeProvider({
owner: '<user>',
repository: '<repo>',
oauthToken: SecretValue.secretsManager('my-github-token'),
}),
autoBranchCreation: { // Automatically connect branches that match a pattern set
patterns: ['feature/*', 'test/*'],
},
autoBranchDeletion: true, // Automatically disconnect a branch when you delete a branch from your repository
});
Properties
Name | Type | Description |
---|---|---|
auto | boolean | Whether to enable auto building for the auto created branch. |
basic | Basic | The Basic Auth configuration. |
build | Build | Build spec for the auto created branch. |
environment | { [string]: string } | Environment variables for the auto created branch. |
patterns? | string[] | Automated branch creation glob patterns. |
pull | string | The dedicated backend environment for the pull request previews of the auto created branch. |
pull | boolean | Whether to enable pull request preview for the auto created branch. |
stage? | string | Stage for the auto created branch. |
autoBuild?
Type:
boolean
(optional, default: true)
Whether to enable auto building for the auto created branch.
basicAuth?
Type:
Basic
(optional, default: no password protection)
The Basic Auth configuration.
Use this to set password protection for the auto created branch.
buildSpec?
Type:
Build
(optional, default: application build spec)
Build spec for the auto created branch.
environmentVariables?
Type:
{ [string]: string }
(optional, default: application environment variables)
Environment variables for the auto created branch.
All environment variables that you add are encrypted to prevent rogue access so you can use them to store secret information.
patterns?
Type:
string[]
(optional, default: all repository branches)
Automated branch creation glob patterns.
pullRequestEnvironmentName?
Type:
string
(optional, default: automatically provision a temporary backend)
The dedicated backend environment for the pull request previews of the auto created branch.
pullRequestPreview?
Type:
boolean
(optional, default: true)
Whether to enable pull request preview for the auto created branch.
stage?
Type:
string
(optional, default: no stage)
Stage for the auto created branch.