Docker--2

﹥>﹥吖頭↗ 提交于 2020-01-19 00:06:52

文章目录

https://download.docker.com/linux/centos/7/x86_64/stable/Packages/

ipconfig

systemctl stop firewalld

systemctl disable firewalld

getenforce

systemctl start iptables

systemctl start iptables

yum -y install iptables-services

systemctl start iptables

systemctl enable iptables

iptables -F

service iptables save


yum update

reboot

rz -E

mkdir docker

mv docker* docker

cd docker/

yum -y install *

systemctl start docker

systemctl enable docker

systemctl status docker

docker run hello-world

cp /lib/systemd/system/docker.service /etc/systemd/system/docker.service

chmod a+x /etc/systemd/system/docker.service

vim /etc/systemd/system/docker.service

    ExecStart=/usr/bin/dockerd-current --registry-mirror=https://registry.docker-cn.com

systemctl daemon-reload

systemctl restart docker

ps -ef | grep docker


WordPress构建

docker pull wordpress

docker pull mariadb



docker run --name db --env MYSQL_ROOT-PASSWORD=example -d mariadb
docker run --name MyWordPress --link db:mysql -p 8080:80 -d wordpress
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!