前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >Harbor仓库问题处理

Harbor仓库问题处理

作者头像
行 者
发布2023-10-20 14:43:46
3300
发布2023-10-20 14:43:46
举报
文章被收录于专栏:运维技术迷运维技术迷

一、 unauthorized: authentication required

代码语言:javascript
复制
[root@LWS-NODE-JP software]# docker login https://harbor.nginx.top
Username: admin
Password: 
Error response from daemon: Get "https://harbor.nginx.top/v2/": unauthorized: authentication required

解决

代码语言:javascript
复制
解决方法一:
引用自: https://github.com/goharbor/harbor/issues/3114#issuecomment-424992795

在common/config/registry/config.yml中修改realm为https

解决方法二:
引用自: https://github.com/goharbor/harbor/issues/3114#issuecomment-394139225

删除/注释掉common/config/nginx/nginx.conf中的proxy_set_header X-Forwarded-Proto $scheme;

操作如下: 

sed -i '/X-Forwarded-Proto/d' common/config/nginx/nginx.conf
docker restart nginx

二、 Retrying in XXX seconds

docker push harbor 反复Retrying in XXX second

代码语言:javascript
复制
[root@LWS-NODE-JP dockerfile]# docker push harbor.nginx.top/test/alpine:3.15
The push refers to repository [harbor.nginx.top/test/alpine]
8d3ac3489996: Retrying in 9 seconds 

解决

代码语言:javascript
复制
[root@harbor harbor]# vim common/config/registry/config.yml 

http:
  addr: :5000
  secret: placeholder
  debug:
    addr: localhost:5001
  relativeurls: true # 添加此行
本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2022-01-20,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • 一、 unauthorized: authentication required
  • 解决
  • 二、 Retrying in XXX seconds
  • 解决
相关产品与服务
容器镜像服务
容器镜像服务(Tencent Container Registry,TCR)为您提供安全独享、高性能的容器镜像托管分发服务。您可同时在全球多个地域创建独享实例,以实现容器镜像的就近拉取,降低拉取时间,节约带宽成本。TCR 提供细颗粒度的权限管理及访问控制,保障您的数据安全。
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档