Install Docker CE community edition in CentOS 7

Source: Internet
Author: User
Tags docker run

Install Docker CE community edition in CentOS 7

Docker CE for CentOS

Package docker ce has no installation candidate 

Features and advantages

It is easy to install and set up an optimized Docker environment for CentOS distribution on bare metal servers and virtual machines. The latest Docker platform version has built-in business processes (clusters and scheduling), runtime security, container network and volumes, and Docker CE can be downloaded for free, the monthly Edge or quarterly stable version supported by the Community is also provided. Docker EE subscription includes quarterly versions. Each version has one-year maintenance and SLA enterprise-level support.

Install Docker ce on CentOS

Install docker ce

Uninstall old version

The old version of Docker is called docker or docker engine. If these are already installed, uninstall them and their associated dependencies.
Sudo yum remove docker \
Docker-common \
Docker-selinux \
Docker-engine

Docker ce install

CentOS 7.3 64-bit support for Docker CE

Set the Docker CE repository on CentOS
Sudo yum install-y yum-utils

Sudo yum-config-manager \
-- Add-repo \

Docker ce has no installation candidate
Https://download.docker.com/linux/centos/docker-ce.repo

Sudo yum makecache fast

Install docker ce on ubuntu

Optional. Enable edge and test repositories. These repositories are included in the preceding docker. repo file, but are disabled by default. You can enable them with a stable repository.
Sudo yum-config-manager -- enable docker-ce-edge

Sudo yum-config-manager -- enable docker-ce-test
# Disable

Install docker ce in ubuntu
Sudo yum-config-manager -- disable docker-ce-edge

Install the latest Docker CE version on CentOS

Sudo yum-y install docker-ce
# Start docker
Sudo systemctl start docker

On the production system, we can install a specific version of Docker CE instead of always using the latest version. List available versions. This example uses the sort-r command to sort the result by version number, from the highest to the lowest, and is truncated.
[Root @ aniu-k8s yum. repos. d] # yum list docker-ce -- showduplicates | sort-r
* Updates: mirrors.cn99.com
Loading mirror speeds from cached hostfile
Loaded plugins: fastestmirror
Installed Packages
* Extras: mirrors.shuosc.org
* Epel: mirrors.tongji.edu.cn
Docker-ce.x86_64 17.09.0.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 172.169.0.ce-1. el7.centos @ docker-ce-stable
Docker-ce.x86_64 17.06.2.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 17.06.1.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 172.166.0.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 17.03.2.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 17.03.1.ce-1. el7.centos docker-ce-stable
Docker-ce.x86_64 17.03.0.ce-1. el7.centos docker-ce-stable
# To install a specified version, refer: install docker ce ubuntu
Sudo yum install <FULLY-QUALIFIED-PACKAGE-NAME> (17.06.2.ce-1. el7.centos)

Test Docker CE Installation
Sudo docker run hello-world1

To upgrade Docker CE, you can download the latest version of rpm and upgrade it with yum localinstall rpm-name.

Uninstall Docker CE

Sudo yum remove docker-ce
Sudo rm-rf/var/lib/docker

For more Docker tutorials, see the following:

Docker installation application (CentOS 6.5_x64) https://www.bkjia.com/Linux/2014-07/104595.htm
Configuration on Ubuntu 16.04 server using Docker https://www.bkjia.com/Linux/2017-06/145176.htm
Install Docker https://www.bkjia.com/Linux/2015-07/120444.htm in Ubuntu 15.04
Docker installation instance https://www.bkjia.com/Linux/2017-04/142666.htm
Docker create basic image https://www.bkjia.com/Linux/2017-05/144112.htm
How to install Docker and basic usage https://www.bkjia.com/Linux/2015-09/122885.htm on Ubuntu 15.04
Docker Use note https://www.bkjia.com/Linux/2016-12/138490.htm on Ubuntu 16.04
Use Docker to start https://www.bkjia.com/Linux/2017-04/142649.htm of frequently used applications in minutes
Ubuntu 16.04 Docker modify configuration file does not take effect solution https://www.bkjia.com/Linux/2017-05/143862.htm

Docker details: click here
Docker: click here

Reference
Https://docs.docker.com/engine/installation/linux/docker-ce/centos

This article permanently updates link: https://www.bkjia.com/Linux/2018-03/151478.htm


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.