shipyard 中文版安装 -- Docker web管理
#本文使用markdown文档格式
#Docker web管理平台
#shipyard 中文版安装
#hipyard可对容器、镜像、仓库、docker节点进行管理的web系统
#++++++++++++++++++++++++++++++
#docker基本安装
#环境centos7
#配置docker阿里源
echo '#Docker
[docker-ce-stable]
name=Docker CE - Aliyun
baseurl=https://mirrors.aliyun.com/docker-ce/linux/centos/7/x86_64/stable/
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/docker-ce/linux/centos/gpg
'>/etc/yum.repos.d/docker-ce.repo
yum makecache fast
#安装必要的系统工具
#yum install -y device-mapper-persistent-data lvm2
#安装 docker-ce
yum install -y docker-ce
#启动docker
systemctl enable docker
systemctl start docker
docker version #查查版本
docker info #查看info
#默认镜像源慢,配置镜像加速
#申请阿里云加速https://dev.aliyun.com
#xxoo.mirror.aliyuncs.com替换为自己的加速网址
SetOPTS="--registry-mirror=https://xxoo.mirror.aliyuncs.com"
sed -i "s#^ExecStart.*#& $SetOPTS #" /usr/lib/systemd/system/docker.service
grep 'ExecStart' /usr/lib/systemd/system/docker.service
#重启服务
systemctl daemon-reload
systemctl restart docker
ps -ef|grep docker #查看进程参数
#++++++++++++++++++++++++++++++
#shipyard安装
#安装主服务器 docker-1
#1.下载镜像
docker pull rethinkdb
docker pull microbox/etcd
docker pull shipyard/docker-proxy
docker pull swarm
docker pull dockerclub/shipyard
#2.修改安装脚本(修改为中文镜像)
wget https://shipyard-project.com/deploy
grep -n shipyard:latest deploy
sed -i 's#shipyard/shipyard:latest#dockerclub/shipyard:latest#g' deploy
#若8080端口被使用,需修改端口,改为8090试列
#grep -n 'PORT:-8080' deploy
#sed -i 's/PORT:-8080/PORT:-8090/g' deploy
#3.安装与删除
sh deploy #安装
#cat deploy | ACTION=remove bash #删除
#4.访问shipyard
#浏览器输入:http://主机IP:8080
#账号:admin
#密码:shipyard
#添加节点
curl https://shipyard-project.com/deploy | ACTION=node DISCOVERY=etcd://172.16.50.26:4001 bash
#172.16.50.26是主节点ip
#++++++++++++++++++++++++++++++
#停止所有容器
docker stop $(docker ps -a -q)
#删除所有容器(谨慎使用)
docker rm -f $(docker ps -a -q)
本文来自博客园,作者:blog-elvin-vip,转载请注明原文链接:https://www.cnblogs.com/elvi/p/8341401.html