013-docker-安装-Centos7

1、搜索镜像

docker search centos

2、拉取合适镜像

选择合适tag:https://hub.docker.com/,下载合适版本

docker pull centos:6.6

docker images

3、使用镜像

docker run -dit --privileged --name=centos66 centos:6.6 /bin/bash

命令说明:

docker ps 查看运行机器

进入docker :docker exec -it centos66 /bin/bash

查看内核版本:uname -a

查看Centos版本:cat /etc/redhat-release

 
原文地址:https://www.cnblogs.com/bjlhx/p/11757189.html