Docker CE (Community Edition) is the perfect platform for novel users to learn about Docker and container-based applications. In this platform, various discussions are carried out related to Docker, including updates and solutions to different problems faced by Docker users.
There are two types of update channels in Docker CE, one is stable, and the other is an edge. The stable updates every three months, whereas on edge, users are notified of the new features every month.
In this write-up, the installation method of the Docker Ce will be demonstrated for Ubuntu 22.04.
How to Install Docker-CE on Ubuntu 22.04?
The Docker-CE installation is performed by adding its repository to the apt list of Ubuntu 22.04. To do so, the step-by-step procedure is provided below:
Step 1: Download and Add the GPG Key of Docker-CE
First, download the GPG key of the Docker repository using the curl command:
$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/docker-archive-keyring.gpg
Step 2: Add the Docker-CE Repository
After this, add the repository of Docker-CE on Ubuntu 22.04:
$ sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
Once the Docker-CE repository is added, update the system packages list using the command:
$ sudo apt update
Step 3: Install Docker-CE
Now, the Docker-CE is ready to install using the command:
$ sudo apt install docker-ce docker-ce-cli containerd.io -y
To confirm the installation of Docker-CE, display the version of Docker:
$ docker version
Step 4 (Optional): Manage the Docker Service
The Docker service can also be managed using the systemctl utility. First, check the status of Docker using the systemctl command:
$ sudo systemctl status docker
The Docker service is in active status. Similarly, the “systemctl” can restart/stop the Docker service.
How to Remove Docker-Ce from Ubuntu 22.04?
If the Docker-CE is of no use, it can be removed from Ubuntu to free up the space for other applications to be installed. For this purpose, run the command:
$ sudo apt purge docker-ce docker-ce-cli containerd.io -y
The package has been removed along with all its configuration data.
That’s it from this detailed guide!
To install Docker-CE in Ubuntu 22.04, open the terminal and run the command ”sudo apt install docker-ce docker-ce-cli containerd.io -y”. Docker’s community edition is helpful for users to get information about updates and solutions to several problems. In this blog, a detailed installation method of Docker-CE has been demonstrated on Ubuntu 22.04.