gpt4 book ai didi

gitlab - 错误未授权 : HTTP Basic: Access denied on docker push registry. gitlab.com

转载 作者:行者123 更新时间:2023-12-03 19:14:31 26 4
gpt4 key购买 nike

我有以下错误:

docker push registry.gitlab.com/user/rep-name

The push refers to repository [registry.gitlab.com/user/rep]
f319ccdf8ee4: Preparing
..
7032a7172c0a: Preparing
b16cd70f3a2c: Waiting
...
unauthorized: HTTP Basic: Access denied

但是上一个登录成功了:
docker login registry.gitlab.com
Username: user
Password:
Login Succeeded

docker 版本:
docker -v
Docker version 19.03.8, build afacb8b7f0

我使用的个人访问 token 是“api”
https://gitlab.com/profile/personal_access_tokens

因为我有 2-factor ahorization。

最佳答案

我改变:

  • 个人访问 token 范围:
    https://gitlab.com/profile/personal_access_tokens到“api”和“read_registry”
  • docker login 中的用户名从@user 到 user@example.com

  • 现在它是有效的。

    似乎问题在“read_registry”范围内。
    这很奇怪,因为“api”也有读取权限。
    来自 Gitlab:

    Grants complete read/write access to the API, including all groups and projects, the container registry, and the package registry.

    关于gitlab - 错误未授权 : HTTP Basic: Access denied on docker push registry. gitlab.com,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61197872/

    26 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com