I install the harbor with non-root user, and the user has sudo all permission.
But I can not login after I run sudo ./install.sh
docker login -u admin -p "xxx"
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
Error response from daemon: login attempt to http://
logs as follow:
✔ ----Harbor has been installed and started successfully.----
3e52a65a9311 goharbor/harbor-core:v1.7.1 "/harbor/start.sh" 3 minutes ago Restarting (2) 16 seconds ago
c6f5619109b4 goharbor/registry-photon:v2.6.2-v1.7.1 "/entrypoint.sh /etc…" 3 minutes ago Restarting (1) 24 seconds ago registry
0d39806ca5c3 goharbor/harbor-registryctl:v1.7.1 "/harbor/start.sh" 3 minutes ago Restarting (1) 25 seconds ago
Apr 24 10:22:40 172.17.0.1 registryctl[2254]: 2019-04-24T02:22:40Z [FATAL] [main.go:82]: Failed to load configurations with error: open /etc/registryctl/config.yml: permission denied
Please check the file permission on ./common/config/registryctl/config.yml
./common/config/registryctl/config.yml permission is
-rw-r--r-- 1 root root 108 Apr 24 18:04 config.yml
but the non-root user has sudo ALL permission and I also try to su -c - root ‘sh ./install.sh’
The result is the same error
我也遇到同样的问题,经查原因:是core访问registry的5000端口被拒绝,但是访问其他的容器没问题(I encountered the same problem, which was found to be due to the fact that 5000 ports of core access to registry were denied, but access to other containers was fine)

我是用root用户部署的(I deployed it with root users.)
我是用root用户部署的(I deployed it with root users.)
thx, I have already install using root, but I find the harbor install documents using sudo
I have same problem. My OS is ubuntu:16.04. and I solved by modify ~/.docker/config.json
"noProxy": "127.0.0.1,localhost,harbor-core,harbor-db,harbor-jobservice,harbor-log,harbor-portal,nginx,redis,registry,registryctl" it set noproxy=registry in harbor-core env
我也遇到同样的问题,经查原因:是core访问registry的5000端口被拒绝,但是访问其他的容器没问题(I encountered the same problem, which was found to be due to the fact that 5000 ports of core access to registry were denied, but access to other containers was fine)
您怎么解决的呢
because some files are generated in docker is root permission.
and the non-root user cannot access these files.
I have already sloved this proble, because the main process harbor-core need the no-root but harbor user. This file maybe no permission for harbor in containers. So I create the harbor user in my host server and give the 10000:10000 to harbor, then add the harbor into root group.
use sudo ./install.sh