鍍金池/ 問答/iOS  Linux  網(wǎng)絡安全  HTML/ 在HTTP平文協(xié)議安裝的Harbor,為什么從客戶端登陸不了?

在HTTP平文協(xié)議安裝的Harbor,為什么從客戶端登陸不了?

在一臺主機安裝Harbor,使用默認的HTTP協(xié)議。
IP是192.168.33.10。
可以在本機上通過命令行登陸:

sudo docker login 192.168.33.10

也可以從瀏覽器訪問:
http://192.168.33.10
但從其他客戶端(Mac,這樣安裝的docker)登陸時,出現(xiàn)如下錯誤:

docker login 192.168.33.10
Username: user1
Password: (my_password)
Error response from daemon: Get https://192.168.33.10/v2/: dial tcp 192.168.33.10:443: getsockopt: connection refused

從Harbor安裝文檔中可以看到說明:
https://github.com/vmware/har...

IMPORTANT: The default installation of Harbor uses HTTP - as such, you will need to add the option --insecure-registry to your client's Docker daemon and restart the Docker service.

在Harbor主機和客戶機都對這個文件進行設置/etc/docker/daemon.json

{ "insecure-registries":["192.168.33.10"] }

并重啟docker,還是不行。
如果現(xiàn)在不使用HTTPS協(xié)議安裝Harbor,有什么辦法能從客戶端正常登陸訪問?

回答
編輯回答
鹿惑

解決方案

在客戶端不需要設置/etc/docker/daemon.json,Mac不是這么做,而是:
圖片描述

應用并重啟

2017年5月5日 09:57