image-syncer icon indicating copy to clipboard operation
image-syncer copied to clipboard

显示username和password错误

Open userboyboy opened this issue 4 years ago • 6 comments

我想把企业版cr 同步到本地的harbor里。 报错日志如下,我设置的账号和密码是管理员权限 配置在config.json

{ "auth": { "xxx-registry.cn-shanghai.cr.aliyuncs.com": { "username": "sh-container01", "password": "xxx" }, "harbor.xxx.cn": { "username": "admin", "password": "xxx" } }, "images": { "xxx-registry.cn-shanghai.cr.aliyuncs.com/sh-aliyun-cr": "harbor.xxx.cn/sh-aliyun-cr" } }

ERRO[2021-04-25 12:35:15] Generate sync task xxx-registry.cn-shanghai.cr.aliyuncs.com/sh-aliyun-cr to harbor.xxxx.cn/sh-aliyun-cr error: get tags failed from xxx-registry.cn-shanghai.cr.aliyuncs.com/sh-aliyun-cr error: unable to retrieve auth token: invalid username/password: errors: denied: requested access to the resource is denied unauthorized: authentication required

userboyboy avatar Apr 25 '21 04:04 userboyboy

先确定下 unsername 和 password 是不是填对了哈~,可以用 docker 命令试试

hhyasdf avatar Apr 25 '21 09:04 hhyasdf

先确定下unsername和password是不是填对了哈〜,可以用docker命令试试

image 账号密码是对的哈

userboyboy avatar Apr 26 '21 06:04 userboyboy

同步命令是./image-syncer --config=./config.json --namespace=sh-aliyun-cr

userboyboy avatar Apr 26 '21 06:04 userboyboy

解决了么?我也遇到这个问题,密码手动登录是对的,但是写到配置文件里去执行一直报错

youngcool2285 avatar Nov 11 '21 04:11 youngcool2285

使用仓库的token登录试试

imdingtalk avatar Jul 19 '23 14:07 imdingtalk