Changing PR author from CodeBuild

0

Summary: I'm using codebuild to run 'Renovate Bot' on my repository, The 'Renovate Bot' will create pull requests, but the Author of the Pull Request is Overridden by the ARN. (if i'm in EC2 its EC2 ARN, if i'm in codebuild it's Build ARN, if i run it without any amazon resource it's not overridden)

Wanted results: I expect to be able to set my own Author, so i can recognize who opened those Pull requests, every time i run my ci tool, i get the same author from the same bot. this helps recognize who created the PR, so next time when i run the 'Renovate Bot', the bot will be able to spot that it opened this PR.

The case: on the first run the bot creates a PR. on the second run the bot tries to add a comment to the PR.

What i get in this case is this: | "You cannot update this comment. The only person who can update a comment is the IAM user who created it."

so i want my codebuild to create PRs with the same user every run, how do i do that?

see for reference https://github.com/renovatebot/renovate/discussions/23769

已提问 9 个月前197 查看次数
1 回答
0

Hi,

git commits have two identifying pieces of information(author, and committer). AWS CodeCommit used to (it may have changed recently.... I didn't retest) only display the 'committer' in the console and to confusingly label as 'author'). I would guess that your commits have differing author (the true one) and committer (the bot) values.

To validate these values with CodeCommit, you can call the 'get-commit' api directly from the AWS CLI (in region where your repo lives) aws codecommit get-commit --repository-name <repository-name> --commit-id <xyz> to see if you get both as you want.

Best,

Didier

profile pictureAWS
专家
已回答 9 个月前
  • sorry but that doesn't help my case,

    What the bot does is on the first run it creates a PR. on the second run it needs to add a comment on the PR.

    What i get in this case is this: | "You cannot update this comment. The only person who can update a comment is the IAM user who created it."

    so i want my codebuild to create PRs with the same user every run, how do i do that?

    see for reference https://github.com/renovatebot/renovate/discussions/23769

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则

相关内容