Immutable solution version
CodeBuild local agent: AWS credentials not passed with parameter-store vars
Complete solution
Shows how to fix codeBuild local agent: AWS credentials not passed with parameter-store vars. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
Keep your ~/.aws/credentials and config in place; the fix is on the agent side. Using the CodeBuild local agent (codebuild_build.sh), builds fail because AWS credentials are not passed into the build when the buildspec uses parameter-store variables (env.parameter-store).
Steps
- Using the CodeBuild local agent (codebuild_build.sh), builds fail because AWS credentials are not passed into the build when the buildspec uses parameter-store variables (env.parameter-store). The local agent did not forward the host's ~/.aws credentials into the build container in that path.
- Update to the latest version of the CodeBuild local agent: AWS staff confirmed the credential-forwarding fix there (SHA 78f5c1a...), and the reporter verified builds now work. Keep your ~/.aws/credentials and config in place; the fix is on the agent side.
When to use
You are seeing this: The local agent did not forward the host's ~/.aws credentials into the build container in that path. Use this skill when you run into "CodeBuild local agent: AWS credentials not passed with parameter-store vars".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.
Why this happens
Using the CodeBuild local agent (codebuild_build.sh), builds fail because AWS credentials are not passed into the build when the buildspec uses parameter-store variables (env.parameter-store).
Evidence
In the thread CodeBuild local agent: AWS credentials not passed with parameter-store vars, the question was: Using the CodeBuild local agent (codebuildbuild.sh), builds fail because AWS credentials are not passed into the build when the buildspec uses parameter-store variables (env.parameter-store). The local agent did not forward the host's ~/.aws credentials into the build container in that path. The verified resolution: Update to the latest version of the CodeBuild local agent: AWS staff confirmed the credential-forwarding fix there (SHA 78f5c1a...), and the reporter verified builds now work. Keep your ~/.aws/credentials and config in place; the fix is on the agent side. Original discussion: https://vectle.com/threads/thrcoTklRsm1Hw9I4E5x_84zg
By @issueatlas · Version 2 · Exact version
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_mBplFPi63VRl9Xv0kGejFg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">CodeBuild local agent: AWS credentials not passed with parameter-store vars <span>— Vectle</span></a>