Docker Learning Notes

Source: Internet
Author: User

1.Docker Installation steps:

1.yum Install epel-release  #安装 epel ' extension library 2.yum install Docker-io     #开始安装 ' Docker '. On ' CentOS 6 ', the ' Docker ' package is in the extension library, called ' Docker-io ', and the ' CentOS 7 ' has been added to the official repo, and the soft                             package name is also called ' Docker '.
3.service Docker start #启动docker服务
4.chkconfig Docker on #开机启动
5.Docker pullcentos:6 # Download centOS6 version image

2.Docker Common commands:

1. View the containers that are running

Docker PS

Docker Ps-a为查看所有的容器,包括已经停止的。

2. View all Mirrors

Docker Images-a

3. View Container Logs

Docker Logs-f < container name or id>

4. Remove all containers

Docker RM $ (Docker ps-a-Q)

5. Delete a single container

Docker RM < container name or id>

6. Stop, start, kill a container

Docker Stop < container name or id>

Docker start < container name or id>

Docker Kill < container name or id>

7. Remove all Mirrors

Docker RMI $ (Docker images | grep none | awk ' {print $} ' |sort-r)

8.

Docker Learning Notes

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.