- 新しい順
- 投票が多い順
- コメントが多い順
If you are using CodeCommit as Repo you can use an EventBridge trigger to invoke your pipeline:
- Create Eventbridge rule - here is an example rule:
{
"source": ["aws.codecommit"],
"detail-type": ["CodeCommit Repository State Change"],
"resources": ["arn:aws:codecommit:{{region}}:{{account_id}}:Test-Repo"],
"detail": {
"event": ["referenceCreated", "referenceUpdated"],
"repositoryName": ["Test-Repo"],
"referenceType": ["tag"],
"referenceName": [{
"prefix": "dev"
}]
}
}
- Configuring the CodePipeline target by providing the ARN of the created pipeline.
Here are the docs for Eventbrdige: https://docs.aws.amazon.com/eventbridge/
If you are using GitHub you may use a github action for the specific tag and inside the action you can use the AWS CodePipeline Trigger
By doing so we can trigger the pipeline but what about the branch name it is asking at the beginning of the creation of the pipeline would not it pull changes from that branch?
You can just use any branch name and remove that afterwards eg.:
Find out the name of the webhook: aws codepipeline list-webhooks
De-register: aws codepipeline deregister-webhook-with-third-party --webhook-name <webhook-name>
Delete: aws codepipeline delete-webhook --name <webhook-name>
関連するコンテンツ
- AWS公式更新しました 2年前
I am using GitHub