Deployment environment
- Centos7.3 x64
- docker-ce-17.06.0
- docker-compose-1.15.0
- Python-2.7.5 (System default)
Deployment targets
- Using the HTTPS protocol
- Support Clair (will be supported in Harbor1.2 version)
Support HTTPS
Production environment preferably issued by an authoritative CA agency certificate (free recommended STARTSSL), here for testing convenience to use self-signed certificate
-
Create a CA Certificate
OpenSSL req-newkey rsa:4096-nodes-sha256-keyout ca.key-x509-days 365-out ca.crt
-
Generate CSR Public key
OpenSSL req-newkey rsa:4096-nodes-sha256-keyout hub.wow.key-out HUB.WOW.CSR
-
Issuing certificates
OpenSSL x509-req-days 365- in Hub.wow.csr-ca ca.crt-cakey ca.key-cacreateserial-out hub.wow.crt
-
Deploying certificates
CP hub.wow.crt hub.wow.key/data/harbor/keys//data/harbor/==/data/harbor/ keys/=/data/harbor/keys//data/Harbor. /Prepare rebuild configuration file Docker-compose Downdocker-compose up
-
Access private warehouses via HTTPS
webui:https://~]# Docker login-u admin-p Harbor12345 hub.wowLogin succeeded
Problem
Docker login prompts x509:certificate signed by unknown authority
workaround : Self-signed certificate is not trusted by the system, requires CP ca.crt/etc/docker/certs.d/hub.wow/, no need to restart Docker
Enterprise-Class Docker Private warehouse Deployment (HTTPS)