Find which resource triggered CodePipeline when mu

2019-08-27 11:02发布

I'm using AWS and created a CodePipeline using multiple resources (CodeCommit). I properly getting events like this:

{'CodePipeline.job': {'id': '...

In this event I can find the latest commit for each CodeCommit resource but I did not find how I can determine which specific resource triggered the CodePipeline execution. Is it something doable ? Thanks for your help.

2条回答
一纸荒年 Trace。
2楼-- · 2019-08-27 11:51

It is not supported yet, but will be in the future. Right now, maybe you could work around by tracking the eventname of StartPipelineExecution in cloudtrail and compare it with the commit time of the source.

查看更多
劫难
3楼-- · 2019-08-27 11:56

I am pretty sure you can get the commit message from codepipeline:

aws codepipeline get-pipeline-state --name PIPELINE_NAME

try parsing it using jq, or bash

查看更多
登录 后发表回答