Skip to content

Commit

Permalink
fix(codepipeline-actions): use BatchGetBuildBatches permission for ba…
Browse files Browse the repository at this point in the history
…tch builds (#13018)

My mistake in #11741 🤦 

For batch builds the pipeline needs `codebuild:BatchGetBuildBatches`, not `codebuild:BatchGetBuilds`
  • Loading branch information
tjenkinson committed Feb 12, 2021
1 parent ee8699a commit 09ba573
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ export class CodeBuildAction extends Action {
options.role.addToPolicy(new iam.PolicyStatement({
resources: [this.props.project.projectArn],
actions: [
'codebuild:BatchGetBuilds',
`codebuild:${this.props.executeBatchBuild ? 'BatchGetBuildBatches' : 'BatchGetBuilds'}`,
`codebuild:${this.props.executeBatchBuild ? 'StartBuildBatch' : 'StartBuild'}`,
`codebuild:${this.props.executeBatchBuild ? 'StopBuildBatch' : 'StopBuild'}`,
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@
},
{
"Action": [
"codebuild:BatchGetBuilds",
"codebuild:BatchGetBuildBatches",
"codebuild:StartBuildBatch",
"codebuild:StopBuildBatch"
],
Expand Down

0 comments on commit 09ba573

Please sign in to comment.