1 上传安装包:
docker-ce-18.06.0.ce-3.el7.x86_64.rpm
2. 安装:
yum install docker-ce-18.06.0.ce-3.el7.x86_64.rpm -y
3 .启动docker
systemctl start docker
systemctl stop docker
systemctl restart docker
systemctl status docker
docker info
4 搜索镜像
docker search tomcat
5 下载镜像:
docker pull tomcat
docker pull openjdk
6 导入镜像:
#docker load -i centos7.tar
#docker load -i java8.tar
#docker load -i tomcat.tar
#docker load -i nginx.tar
docker load -i mysql.tar
7创建mysql容器:
docker run -di --name=m1 -p 3307:3306 -e MYSQL_ROOT_PASSWORD=123456 -e MYSQL_DATABASE=docker001 mysql:5.7