You can install Harbor in different configurations:
- Just Harbor, without Notary, Trivy or Chart Repository Service
- Harbor with Notary
- Harbor with Chart Repository Service
- Harbor with two or all three of Notary, Trivy, and Chart Repository Service
The default Harbor installation does not include Notary or Trivy service. Run the following command
If the installation succeeds, you can open a browser to visit the Harbor interface at http://reg.yourdomain.com
, changing reg.yourdomain.com
to the hostname that you configured in harbor.yml
. If you did not change them in harbor.yml
, the default administrator username and password are admin
and Harbor12345
.
Log in to the admin portal and create a new project, for example, . You can then use Docker commands to log in to Harbor, tag images, and push them to Harbor.
docker login reg.yourdomain.com
docker push reg.yourdomain.com/myproject/myrepo:mytag
- If your installation of Harbor uses HTTPS, you must provide the Harbor certificates to the Docker client. For information, see .
- If your installation of Harbor uses HTTP, you must add the option
--insecure-registry
to your client’s Docker daemon and restart the Docker service. For more information, see Connecting to Harbor via HTTP below.
Installation with Notary
To install Harbor with the Notary service, add the --with-notary
parameter when you run install.sh
:
sudo ./install.sh --with-notary
For more information about Notary and Docker Content Trust, see Content Trust in the Docker documentation.
To install Harbor with Trivy service, add the --with-trivy
parameter when you run install.sh
:
For more information about Trivy, see the . For more information about how to use Trivy in an webproxy environment see Configure custom Certification Authorities for trivy
Installation with Chart Repository Service
To install Harbor with chart repository service, add the parameter when you run install.sh
:
sudo ./install.sh --with-chartmuseum
If you want to install both Notary and chart repository service, specify all of the parameters in the same command:
Connecting to Harbor via HTTP
For example, add the following to your daemon.json
file:
After you update daemon.json
, you must restart both Docker Engine and Harbor.
Restart Docker Engine.
systemctl restart docker
Stop Harbor.
Restart Harbor.
- If the installation succeeds, see for information about using Harbor.
- If you deployed Harbor with HTTP and you want to secure the connections to Harbor, see Configure HTTPS Access to Harbor.
- If installation fails, see .