awslabs / awslabs/aws-codebuild-jenkins-plugin
Running CodeBuild on Docker Container uses Master Role and NOT Agent Role
- Dominant language
- Java
- Stars
- 156
- Forks
- 130
- PR merge metrics
- No merged PRs in 30d
Description
Hello, my Jenkins is setup on ECS Fargate. We trigger builds using Jenkins ECS Plugin which launches a docker agent and runs jobs on it. The issue sounds similar where it seems to keep picking the Master Role rather then the Agent Role with Codebuild Plugin.
When I run sh 'aws sts get-caller-identity'. I get the right role information. As soon as I run the Codebuild plugin, it starts seeing the Master Role. Not sure how Codebuild plugin is picking up Master Role when running "aws sts get-caller-identity' right before shows the correct Agent Role.
JadyLiu had a similar issue here https://github.com/awslabs/aws-codebuild-jenkins-plugin/issues/16.
Contributor guide
Research direction
Start by reproducing the Jenkins ECS Fargate setup described in the issue, comparing `aws sts get-caller-identity` immediately before the CodeBuild plugin runs with the role used by CodeBuild. The issue is resolved when the plugin uses the ECS agent role rather than the Jenkins master role.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, docker, java
- Domain
- ci-cd, cloud, devops
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100