Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide guidance on making secret service work #132

Open
p opened this issue Dec 29, 2018 · 3 comments
Open

Provide guidance on making secret service work #132

p opened this issue Dec 29, 2018 · 3 comments

Comments

@p
Copy link

p commented Dec 29, 2018

On Debian, docker appears to be configured to use secret service by default. However, this did not work on my machine:

# docker login -u user -p pass
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
** Message: 00:51:34.306: Remote error from secret service: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.secrets was not provided by any .service files
Error saving credentials: error storing credentials - err: exit status 1, out: `The name org.freedesktop.secrets was not provided by any .service files`

My internet searches for "secret service" yielded freedesktop specifications for it but nothing related to which program I need to have installed to have it, or how to start it.

From my experience, freedesktop bits do not always come with adequate user documentation, but since it is rather non-trivial to figure out how to make docker not try to use the various gnome desktop services (docker/cli#1219), please consider adding some guidance on how to make the default credential store work, including on a headless machine with no X installed.

@flipsa
Copy link

flipsa commented Dec 30, 2021

Commenting here since I had the same problem and a Google search lead me here and didn't yield much otherwise...

Having the 'pass' password manager installed fixes this for me on a headless Debian Buster (but then stores the saved credentails unencrypted...):

$ sudo apt install pass
...
...
...
$ docker login 
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one.
Username: ***********
Password: 
WARNING! Your password will be stored unencrypted in /home/xxxxxxxxx/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store

Login Succeeded

@tucked
Copy link

tucked commented May 4, 2023

Just hit this on openSUSE... I've tried reinstalling, and I've tried nuking ~/.docker/config.json without any luck.

@tucked
Copy link

tucked commented May 4, 2023

Apparently docker-credential-secretservice just doesn't work on headless machines...

I worked around by using docker-credential-pass instead...
First, download docker-credential-pass from GitHub: https://github.com/docker/docker-credential-helpers/releases/

sudo zypper install gpg2 password-store
pass init $YOUR_GPG_ID  # if you don't have one: gpg2 --full-generate-key && gpg2 -k
# Make sure docker-credential-pass is on $PATH (e.g. in /usr/local/bin or ~/bin)
docker login

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants