docker-credential-helpers
docker-credential-helpers copied to clipboard
"docker-credential-pass": executable file not found in $PATH
Apologies, this may be the wrong place for this, I'm just not sure where to start as it could be an issue with the credential helper, Docker, the snap or the Ubuntu setup.
I'm running Ubuntu 18.04 with Docker installed via snap, Docker is version 19.03.11.
I'm trying to get docker login
to work with pass
. pass
works fine with my physical key on its own.
My Docker config file in ~/snap/docker/current/.docker/config.json looks like this:
{
"credsStore": "pass",
"HttpHeaders": {
"User-Agent": "Docker-Client/19.03.8 (linux)"
}
}
I've installed docker-credential-pass
in /usr/bin
and it's version 0.6.3.
However, when I run docker login
, after entering my credentials, I always get this error:
Error saving credentials: error storing credentials - err: exec: "docker-credential-pass": executable file not found in $PATH, out: ``
docker-credential-pass
is in the path, and is found if I run the command directly and if I type which docker-credential-pass
. I've even tried putting it in a folder within my home folder which is in the path, in case that helps (I know Docker snap has some restrictions about where on the file system it can access). However, I'm still left with docker login
failing to find docker-credential-pass
.
Any ideas?
Same here with upstream debian buster package.
docker-credential-pass
extracted to ~/.local/bin
$ which docker-credential-pass
~/.local/bin/docker-credential-pass
My ~/.docker/config.json
:
{
"credsStore": "pass"
}
$ docker login registry.example.com
Error saving credentials: error storing credentials - err: exit status 1, out: `pass not initialized: exec: "pass": executable file not found in $PATH:`
Also tried:
{
"credsStore": "docker-credential-pass"
}
$ docker login registry.example.com
Error saving credentials: error storing credentials - err: exec: "docker-credential-docker-credential-pass": executable file not found in $PATH, out: ``
:neutral_face:
(I know Docker snap has some restrictions about where on the file system it can access)
Looks like you was right. I just moved docker-credential-pass
to /usr/local/bin
and it's work.
(I know Docker snap has some restrictions about where on the file system it can access)
Looks like you was right. I just moved
docker-credential-pass
to/usr/local/bin
and it's work.
What does this mean for us that don't use docker-credential-pass?
I mean, what is the workaround when
{
"credsStore": "pass"
}
yields
https://index.docker.io/v1/: error erasing credentials - err: exec: "docker-credential-pass": executable file not found in $PATH, out: ``
cd /home/youruser
mv .docker .docker-old
or you can remove it. try again
docker login
looks like this was resolved
When using this "solution", I still get the warning: WARNING! Your password will be stored unencrypted in /home/myusername/.docker/config.json.
So this is not resolved
# Install "pass" for Linux https://www.passwordstore.org/
sudo apt install pass
# Generate a pub/secret key
gpg --full-generate-key
# Init the pass store
pass init "<KEYID_GENERATED_BY_GPG>"
docker login