Docker login error 401

i am using gitlab docker, traefik.
With normal git functions there are no problems.
If I use with https, I get the 401 error.
With registry I use traefik.
By making docker login, I get the following error:
docker login
Authenticating with existing credentials …
Login did not succeed, error: Error response from daemon: login attempt to failed with status: 401
I get the same mistake even with the use of tokens.

What can I do?

Thank you

@esoul Is this from Using CI or from the command line? Are you trying to use CI_JOB_TOKEN to login?

This might be a helpful reference:

1 Like

I use to authenticate the token in this way.
docker login -u _token_name -p
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
Error response from daemon: Get denied: access forbidden

In Active Personal Access Tokens I have the following scopes: api, read_user, read_registry, sudo.
I currently use swarm with traefik.
I’m not using gitlab runner right now but I don’t think that’s the login problem.

Thank you