Get Docker CE for CentOS
//https://docs.docker.com/install/linux/docker-ce/centos/
To get started with Docker CE on CentOS, make sure you meet the prerequisites, then install Docker.
// meet vt. 滿足;遇見;對付 prerequisite n.先決條件
Prerequisites
OS requirements
To install Docker CE, you need a maintained version of CentOS 7. Archived versions aren’t supported or tested.
The centos-extras
repository must be enabled. This repository is enabled by default, but if you have disabled it, you need to re-enable it.
The overlay2
storage driver is recommended.
Uninstall old versions
Older versions of Docker were called docker
or docker-engine
. If these are installed, uninstall them, along with associated dependencies.
$ sudo yum remove docker docker-client docker-client-latest docker-common docker-latest docker-latest-logrotate docker-logrotate docker-selinux docker-engine-selinux docker-engine
It’s OK if yum
reports that none of these packages are installed. //如果yum 報告這些包都沒有安裝,那也沒關系
The contents of /var/lib/docker/
, including images, containers, volumes, and networks, are preserved. The Docker CE package is now called docker-ce
.
//preserved [pr?‘z??vd] adj. 保藏的;
Install Docker CE
You can install Docker CE in different ways, depending on your needs:
-
Most users set up Docker’s repositories and install from them, for ease of installation and upgrade tasks. This is the recommended approach.
-
Some users download the RPM package and install it manually and manage upgrades completely manually. This is useful in situations such as installing Docker on air-gapped systems with no access to the internet. //氣隙系統(Air-gapped)是一種將電腦進行完全隔離(不與互聯網以及任何其他聯網設備連接)以保護數據安全的系統
-
In testing and development environments, some users choose to use automated convenience scripts to install Docker.
Get Docker CE for CentOS