How to deploy a private registry to preserve the container images
Harbor is an open source registry that secures artifacts with policies and role-based access control, ensures images are scanned and free from vulnerabilities, and signs images as trusted. Harbor, a CNCF Graduated project, delivers compliance, performance, and interoperability to help you consistently and securely manage artifacts across cloud native compute platforms like Kubernetes and Docker.
Installation Prerequisites:
Harbor is deployed as several Docker containers. You can therefore deploy it on any Linux distribution that supports Docker. The target host requires Docker, and Docker Compose to be installed.
Hardware
The following table lists the minimum and recommended hardware configurations for deploying Harbor.
Resource | Minimum | Recommended |
CPU | 2 CPU | 4 CPU |
Mem | 4 GB | 8 GB |
Disk | 40 GB | 160 GB |
Software
The following table lists the software versions that must be installed on the target host.
Software | Version |
Docker Engine | Version 20.10.10-ce+ or higher |
Docker Compose | docker-compose (v1.18.0+) or docker compose v2 (docker-compose-plugin) |
OpenSSL | Latest is preferred |
Network ports
Harbor requires that the following ports be open on the target host.
Port | Protocol |
443 | HTTPS |
4443 | HTTPS |
80 | HTTP |
Download the Harbor Installer
You download the Harbor installers from the official releases page. Download either the online installer or the offline installer.
Online installer: The online installer downloads the Harbor images from Docker hub. For this reason, the installer is very small in size.
Offline installer: Use the offline installer if the host to which are deploying Harbor does not have a connection to the Internet. The offline installer contains pre-built images, so it is larger than the online installer.
The installation processes are almost the same for the online and offline installers.
Here, we are using an offline installer.
Go to the Harbor releases page.
Download the online or offline installer for the version you want to install.
Use
tar
to extract the installer package:$ tar xzvf harbor-offline-installer-version.tgz
Subscribe to my newsletter
Read articles from MD. Nazmul Alam directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by