Install Docker for CentOS7
Docker is a platform for developers and administrators to develop, deploy, and run applications! It allows you to quickly package applications and deploy applications!
Docker consists of the following two parts:
Docker engine: lightweight and powerful open-source container virtualization technology
Docker Hub: a SaaS (software as a service) service that shares and manages application stacks.
Why Docker?
Fast distribution of applications
Easier deployment and Expansion
High application running density to support running more services
Easy to manage
Docker has been integrated in RHEL7. If you have purchased the Red Hat service, you can directly subscribe to the channel to install it. In RHEL6.5 or later versions, you must first install the epel package, then install; for the installation method and other OS installation method, please refer to the official Docker website https://docs.docker.com/installation/
After a brief introduction above, we will start the installation of Docker!
Install Docker for CentOS7
1. Prepare a centos7 System
For details, refer to the official documents of rhel7 for installation!
2. Install docker
# Yum install docker-y
Install Docker for CentOS6
The Docker installation package is in the EPEL (Extra Packages for Enterprise Linux) repository. To install docker, you must first install the epel repository. Currently, docker only supports 64-bit operating systems, run the following command to install
# Rpm-Uvh http://dl.Fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
Update yum Source
# Yum clean all
# Yum update
# Yum repolist
Install
# Yum install docker-io-y
Start Docker and configure boot (CentOS7)
Start/stop Docker
# Systemctl [start | stop | restart] docker
Configure/cancel startup
# Systemctl [enable | disable] docker