1 Answer
- Newest
- Most votes
- Most comments
2
Implement a manual approval rule in AWS CodePipeline to determine the deployment environment:
Add a manual approval action to your pipeline:
You can add a manual approval action to a stage in your pipeline where you want the execution to stop and wait for someone with the required IAM permissions to approve or reject the action.
When the pipeline reaches the manual approval action, it will stop and wait for the approval. If approved, the pipeline execution will resume. If rejected or no action taken within 7 days, the pipeline execution will fail.
You can customize the approval message and the URL for the reviewer to access more information about the change.
Integrate with a Lambda function:
You can add a Lambda function action to your pipeline that will be invoked after the manual approval.
The Lambda function can then read the approval comments and determine the deployment environment based on the comments.
To access the approval comments, you can use the
#SourceVariables.CommitId
and
#TestVariables.testRunId
variables in the Lambda function configuration.
For more detailed information on implementing these options, I recommend referring to the AWS CodePipeline documentation:
answered 2 years ago
Relevant content
asked 5 years ago
