docker / docker-credential-helpers

Programs to keep Docker login credentials safe by storing in platform keystores
MIT License
1.1k stars 173 forks source link

pass: "exec format error" when trying to login into AWS ECR #314

Open erich-wittenbeck opened 9 months ago

erich-wittenbeck commented 9 months ago

Greetings! I try to register for the AWS Elastic Container Registry to push my Docker images there.

I tried to use docker-credential-pass, which I downloaded from the Releases-Page (latest version), which I saved under /usr/local/bin/

and configured the ~/.docker/config.json like so:

{
        "credsStore": "pass"
}

When I now execute the premade command for logging into the ECR Repository of my AWS Account:

aws ecr get-login-password --region <my-region> | docker login --username AWS --password-stdin <my-account-id>.dkr.ecr.<my-region>.amazonaws.com

...I get the following error message:

Error saving credentials: error storing credentials - err: fork/exec /usr/local/bin/docker-credential-pass: exec format error, out: ``

So far, I couldn't find anything on that error message.

I'd be gratefull for any help!

erich-wittenbeck commented 9 months ago

Ok, so everything seems to be working, when I build docker-credential-pass myself using docker (according to instructions in the main Readme).

Though I'm still wondering, why the executable from the Releases-Page did not work.

nicks commented 9 months ago

"exec format error" usually means you downloaded a binary for the wrong OS or architecture