

Starting, stats and stop a container # docker start My_OS List all the available Docker images on your host # docker imagesĬreating and rune a container # docker run -name My_OS centos cat /etc/hosts

You are choice image and download it locally, use docker pull command # docker pull centos To search for a Docker image, for example, centos image # docker search centos # chkconfig docker on To Learn basic containers, Docker The finish installed docker, To check status, start, enable services docker the below commands: For Centos 6, you install “epel -release” repositories To install docker on centos 7 # yum update -y & yum install epel-release -y & yum install docker -y To install docker on centos 6 # yum update -y & yum install epel-release -y & yum install docker-io -y

This happens when that specific version of containerd.io is not yet added to the CentOS repository.Docker is incorporated into Centos 7 extras repositories, due to install simple. Otherwise, if it fails that the docker-ce requires containerd.io version to be higher than a specific version, then you can fix this by installing the containerd.io manually. If you have successfully installed Docker, then you can skip this step and proceed to configure Docker section. Next, install Docker by running the command: sudo yum install docker-ce docker-ce-cli containerd.io This will remove conflicting podman and buildah: sudo yum erase podman buildah In case that you are getting an error that containerd.io conflicts with runc, or similar below, Now that we have our prerequisites installed, we are now ready to setup Docker.

To add, install the yum-utils first and then add the repo. sudo yum remove docker docker-client docker-client-latest docker-common docker-latest docker-latest-logrotate docker-logrotate docker-engineĪdd the Docker repository in your CentOS machine. To uninstall old docker, run the command below. If you have an older version of Docker, uninstall it first.
