Install Docker Engine on CentOS Linux

To implement available for deployment is one of the most important utility. Hub provides a large number of containers developed by the community. It work as a service and uses a client server architecture . Docker client CLI Tool is responsible for communicating with a server and Docker Server runs as a daemon on an operating system .

Prerequisites for Installation

To install Engine, you need a maintained version of or 8. Archived versions aren’t supported or tested.

  • or CentOs 8 Operating System
  • Centos-extras repository must be working
  • Storage Driver needed overlay2
  • sudo user administrative privilege or root user access
  • working yum repositories

Engine can be installed through different method . One of the important method is add , setup yum repository and install package from their . Another method is package and script method . Here we will use ease method for install and upgrade tasks.

Install using the yum repository

Before setup yum repository we needed config manager utility to add repository , so yum-utils package will be installed. Below command will install that package.

  # yum install -y yum-utils 
Installing yum-utils

After the installation add yum repository to configure docker-ce.repo .Use below command .

  # yum-config-manager --add-repo 
Adding docker-ce.repo

Step to Install Docker Engine

  1. To Install the latest version and containerd use below command
  yum install docker-ce docker-ce-cli  
Installing docker-ce docker-ce-cli

2. Start and Enable the service.

<pre class="codeStyle">  systemctl start docker </pre>
<pre class="codeStyle">  systemctl enable docker </pre>
<pre class="codeStyle">   docker </pre>

Verify by running the hello-world image

   # docker run hello-world 

The output of the above command will show text message of Hello from Docker ! confirm the installation is working correctly.

About Sachin Gupta

I am a professional freelance contributor and founder of tech transit. Love to write and lover of education, culture, and community. I have been using it, setting, supporting, and maintaining it since 2009.Linux rocks!

Have any Question or Comment?

Leave a Reply

Your email address will not be published.