-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(codepipeline): Pipeline should allow pipelineType and variables passthrough to underlying CfnPipeline construct #28476
Labels
@aws-cdk/aws-codepipeline
Related to AWS CodePipeline
effort/medium
Medium work item – several days of effort
feature-request
A feature should be added or improved.
p2
Comments
paihu
added
feature-request
A feature should be added or improved.
needs-triage
This issue or PR still needs to be triaged.
labels
Dec 23, 2023
github-actions
bot
added
the
@aws-cdk/aws-codepipeline
Related to AWS CodePipeline
label
Dec 23, 2023
pahud
added
p2
effort/medium
Medium work item – several days of effort
and removed
needs-triage
This issue or PR still needs to be triaged.
labels
Dec 24, 2023
3 tasks
mergify bot
pushed a commit
that referenced
this issue
Feb 13, 2024
…d triggers (#28538) This PR supports pipeline type v2 with pipeline-level variables and triggers. When referring to a variable in pipeline actions, it must be specified according to the format `#{variables.variableName}`. In order to avoid the need to specify directly in this form, a new class `Variable` with a `reference()` method was created. ```ts const myVariable = new codepipeline.Variable({ variableName: 'bucket-var', description: 'description', defaultValue: 'sample', }); const pipeline = new codepipeline.Pipeline(stack, 'Pipeline', { artifactBucket: sourceBucket, pipelineType: codepipeline.PipelineType.V2, variables: [myVariable], stages: [ { stageName: 'Source', actions: [sourceAction], }, { stageName: 'Deploy', actions: [ new S3DeployAction({ actionName: 'DeployAction', extract: false, // objectKey: '#{variables.bucket-var}.txt', objectKey: `${myVariable.reference()}.txt`, input: sourceOutput, bucket: deployBucket, }), ], }, ], }); ``` - user guide - https://docs.aws.amazon.com/codepipeline/latest/userguide/pipeline-types-planning.html - https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-variables.html#reference-variables-workflow - https://docs.aws.amazon.com/codepipeline/latest/userguide/tutorials-github-tags.html - CloudFormation - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-resource-codepipeline-pipeline.html - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-properties-codepipeline-pipeline-variabledeclaration.html - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-properties-codepipeline-pipeline-pipelinetriggerdeclaration.html Closes #28476 #28694. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
GavinZZ
pushed a commit
that referenced
this issue
Feb 22, 2024
…d triggers (#28538) This PR supports pipeline type v2 with pipeline-level variables and triggers. When referring to a variable in pipeline actions, it must be specified according to the format `#{variables.variableName}`. In order to avoid the need to specify directly in this form, a new class `Variable` with a `reference()` method was created. ```ts const myVariable = new codepipeline.Variable({ variableName: 'bucket-var', description: 'description', defaultValue: 'sample', }); const pipeline = new codepipeline.Pipeline(stack, 'Pipeline', { artifactBucket: sourceBucket, pipelineType: codepipeline.PipelineType.V2, variables: [myVariable], stages: [ { stageName: 'Source', actions: [sourceAction], }, { stageName: 'Deploy', actions: [ new S3DeployAction({ actionName: 'DeployAction', extract: false, // objectKey: '#{variables.bucket-var}.txt', objectKey: `${myVariable.reference()}.txt`, input: sourceOutput, bucket: deployBucket, }), ], }, ], }); ``` - user guide - https://docs.aws.amazon.com/codepipeline/latest/userguide/pipeline-types-planning.html - https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-variables.html#reference-variables-workflow - https://docs.aws.amazon.com/codepipeline/latest/userguide/tutorials-github-tags.html - CloudFormation - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-resource-codepipeline-pipeline.html - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-properties-codepipeline-pipeline-variabledeclaration.html - https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-properties-codepipeline-pipeline-pipelinetriggerdeclaration.html Closes #28476 #28694. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
@aws-cdk/aws-codepipeline
Related to AWS CodePipeline
effort/medium
Medium work item – several days of effort
feature-request
A feature should be added or improved.
p2
Describe the feature
some case pipelineType "V2" is more cost effective.
I want to use Pipeline-level variables for manual trigger pipeline.
https://docs.aws.amazon.com/codepipeline/latest/userguide/pipeline-types-planning.html
https://aws.amazon.com/codepipeline/pricing/
Use Case
We have large Infrastructure. We want partial deploy.
use Manual trigger with Pipeline level variables and set deploy target through variables.
Proposed Solution
add pipelineType and variables to pipelineProps,
pipeline validate variables should set pipelineType "V2"
passthrough these to CfnPipeline
Other Information
No response
Acknowledgements
CDK version used
2.116.1
Environment details (OS name and version, etc.)
windows 11
The text was updated successfully, but these errors were encountered: