How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Permissions error when trying to get codebuild to push to ECR AWS because it's registering as an unknown user

calendar_today August 3, 2024 person Jacob Sanderson domain amazon-codebuild

As the title suggests, my codebuild is not letting me fulfill my buildscript to push the docker image to ECR. It works perfectly when on my local machine, but not in codebuild. The error message is like so: denied: User: arn:aws:iam::311791021927:user/ServerlessAccount is not authorized to perform: ecr:InitiateLayerUpload on resource: arn:aws:ecr:***:014498627014:repository/squared-www because no resource-based policy allows the ecr:InitiateLayerUpload action The issue is, user 311791021927 doesn’t actually exist in my IAM or anywhere, this is my buildspec.yml: version: 0.2 env: secrets-manage

open_in_new Read original post