UbuntuUbuntu Based

How To Install Harbor on Ubuntu 22.04 LTS

Install Harbor on Ubuntu 22.04

In this tutorial, we will show you how to install Harbor on Ubuntu 22.04 LTS. In the realm of containerization and application deployment, Docker has redefined the way we package, distribute, and manage software. Docker images are at the heart of this revolution, and the need for a robust registry to store, manage, and secure these images has never been more critical. This is where the Harbor Docker Image Registry steps in. It is an open-source container image registry that offers features like security, vulnerability scanning, and identity management.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the Harbor Docker image registry on Ubuntu 22.04. You can follow the same instructions for Ubuntu 22.04 and any other Debian-based distribution like Linux Mint, Elementary OS, Pop!_OS, and more as well.


  • A server running one of the following operating systems: Ubuntu 22.04, 20.04, and any other Debian-based distribution like Linux Mint.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • An active internet connection. You’ll need an internet connection to download the necessary packages and dependencies for Harbor.
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install Harbor on Ubuntu 22.04 LTS Jammy Jellyfish

Step 1. Before you start, it’s a good practice to update your system to the latest packages and security patches. Open the terminal and run the following commands:

sudo apt update
sudo apt upgrade

Step 2. Installing Required Packages.

Harbor installation requires some additional packages like curl, wget, and jq. You can install them using the following command:

sudo apt install curl wget jq

These packages are essential for fetching resources and processing JSON data.

Step 3. Installing Harbor Docker Image Registry Dependencies.

Now, let’s install some prerequisites for Harbor. First, install Docker Compose:

sudo apt install docker-compose

After Docker is installed, run the following systemctl command to verify the current status of the Docker service:

sudo systemctl enabled docker
sudo systemctl status docker

You can verify the version of the installation with:

docker-compose --version

With the dependencies in place, let’s obtain the Harbor release package. You can choose the version you want from the Harbor GitHub releases page. Use curl to download it:

curl -LO https://github.com/goharbor/harbor/releases/download/v2.9.1/harbor-online-installer-v2.9.1.tgz

Next, navigate to the directory where you downloaded the Harbor release package and extract it. After extracting, you will find a harbor.yml configuration file. Customize this file to suit your environment. You can use a text editor like nano to make changes:

nano harbor.yml

Inside this configuration file, you can specify various settings like your domain, storage settings, and authentication methods.

Now it’s time to install Harbor with your customized configuration. Use the following command:

sudo ./install.sh

This script will execute the installation, taking your configuration into account. The installation process might take a moment.

Once the installation is complete, you can start and enable Harbor services. Docker Compose is used to manage these services. Run the following commands:

sudo docker-compose up -d

This command starts Harbor services in detached mode, allowing them to run in the background.

Step 4. Access Harbor Web Interface,

Harbor’s web interface provides a user-friendly way to manage container images. To access it, open your web browser and enter the following URL:


Replace your_domain_or_IP with your server’s domain or IP address. You’ll be greeted with the Harbor login page.

Install Harbor on Ubuntu 22.04 LTS Jammy Jellyfish

Congratulations! You have successfully installed Harbor. Thanks for using this tutorial for installing the Harbor Docker image registry on the Ubuntu system. For additional help or useful information, we recommend you check the official Harbor website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!


r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to idroot.us, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button