Methods of payment Abuse

How to deploy your Docker Storage in Ubuntu 20.04

22.12.2022, 17:50

Docker is a tool for working with containers. The main advantage of Docker is the ability to run applications with isolated resources.

To get started, you need to perform a number of steps from the step-by-step instructions:

prepare the server (local or virtual machine);

update packages;

install and configure Docker to work on Ubuntu 20.04.

Step 1. Preparing the server and performing additional work

To deploy the Docker storage, you need to pre-configure the server (including creating a user with non-root rights and checking the firewall settings.

Also, to install the docker storage, you need a Docker Hub account. Without it, the user will not be able to create their own images and upload them to the Docker Hub.

Step 2. Updating Packages

The Docker installation package, which is located in the Ubuntu repo, may contain the latest version. If it is important to work with a fresh update, enter the command:

$ sudo apt update

Before installing Docker, you need to install packages that are designed to work with HTTPS.

Step 3. Installing Docker to work with Ubuntu 20.04

First of all, you need to check that the installation is carried out from the Docker repo, and not the Ubuntu repo (it is used by default). To do this, use the command:

$ apt-cache policy docker-ce

When the installation is completed, an informational message will appear on the screen indicating the version number and other features. From its content, it is clear that docker-ce is a candidate for installation, but has not yet been installed.

To install, enter the command in the command line:

$ sudo apt install docker-ce

After that, the Docker will be installed. To check whether the daemon process is running (this should happen automatically), use the check command:

$ sudo systemctl status docker

Pay attention to the status "Active": it should contain information that the service is active. Additionally, you will see other features of docker-ce (memory, tasks, link to official documentation, and others).

When the Docker is installed, you can work with the settings. For example, to install a startup without sudo and others. Be sure to study the documentation and the list of subcommands that the installed (current) version of Docker works with.