fbpx

What is Docker Engine?

Docker Engine is an open-source client-server technology that builds and runs containers using Docker components and services. It acts as a containerization technology that allows users to interact with the Docker daemon through the Docker Engine API. Docker Engine has a declarative model that automatically adjusts settings and conditions to maintain the desired state of containers. It can run natively on Windows and Apple OSes, and Docker Machine can be used to manage virtual hosts on all OSes. Docker Engine incorporates Docker Swarm directly into the engine, which renamed the orchestration service to swarm mode.

To get started with Docker Engine on Ubuntu, make sure you meet the following prerequisites:

OS requirements


You need the 64-bit version of one of these Ubuntu versions:

Ubuntu Kinetic 22.10
Ubuntu Jammy 22.04 (LTS)
Ubuntu Focal 20.04 (LTS)
Ubuntu Bionic 18.04 (LTS)

Install using the apt repository

The Docker repository has to be set up before you install the Engine for the first time on a new VPS (Virtual Private Server). Following that, you may use the repository to install and update Docker.

Configure the repository

Install packages and update the apt package index to enable apt to utilize an HTTPS repository:

sudo apt-get update
Install Docker Engine using the apt repository
sudo apt-get install \
    ca-certificates \
    curl \
    gnupg
Install Docker Engine

Add the official GPG key for Docker:

sudo mkdir -m 0755 -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
Add the official GPG key for Docker

For the repository setup, enter the following command:

echo \
  "deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
  "$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \
  sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Command for the repository setup

Install Docker Engine

Update the package index:

sudo apt-get update
Update the package index:

Install Engine, containerd, and Docker Compose:

sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
Install Docker Engine, containerd, and Docker Compose:

Run the hello-world image to make sure the Docker installation was successful:

sudo docker run hello-world
Docker Engine hello-world image

2 Comments

Remove Docker Containers, Images, And Volumes - Virtono Community · April 11, 2023 at 1:52 PM

[…] using the prune command, you can delete all the unused Docker objects, including containers, images, networks, and volumes, simultaneously. Here’s an […]

How To Install And Configure Docker Swarm On Ubuntu 22.04 - Virtono Community · September 27, 2023 at 11:48 AM

[…] Docker Installed: Ensure that Docker is already installed on your Ubuntu server. If not, you can refer to our previous article on how to Install Docker on Ubuntu 22.04. […]

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.