Install Docker On CentOS Virtual Machine

In this blog post, I will show you how to install Docker on a CentOS virtual machine running in Azure.


To start the process, I will run the following three commands that will install all the requirements and update the repository.

yum install -y yum-utils
yum-config-manager --add-repo
yum install docker-ce docker-ce-cli

Below, you can see the screenshot of all the packages Docker needs.

Set Docker to AutoStart

To set Docker to auto-start when the server starts, I will run the following commands:

systemctl start docker

Check Version

To check which version Docker has I will run the following command.

docker version