镜像管理:
1.4 总结
- 开源且安装简单
- 中文界面交互友好
- 可执行的操作全面
2.Shipyard
2.1 简介
Docker Swarm 是 Docker 的集群管理工具。Shipyard基于Docker Swarm而创建,能够管理Docker资源,包括容器、镜像、私有仓库等。
Shipyard与其他管理应用程序的不同之处在于具有可组合性,并与Docker远程API 完全兼容。Shipyard管理集群范围内的容器、镜像、节点、私有仓库,并提供身份验证和基于角色的访问控制。
- 用户界面
Shipyard提供便于Docker集群管理的用户界面。它可以管理容器、集群镜像、私有仓库、身份验证等。
- API
Shipyard的核心是API,其Web操作页面最终均使用API实现所有功能。通过使用服务密钥,可以直接与API交互来管理Docker Swarm集群并构建定制集成。
- Database
RethinkDB用于存储帐户、引擎、服务密钥和元数据信息。它不用于存储关于Docker容器或镜像的任何信息。/data目录作为卷公开。
https://shipyard-project.com/manual-deployment/
2.2 安装
2.2.1 Datastore
As mentioned, Shipyard uses RethinkDB for the datastore. First we will launch a RethinkDB container.
docker run \
-ti \
-d \
--restart=always \
--name shipyard-rethinkdb \
rethinkdb
2.2.2 Discovery
To enable Swarm leader election, we must use an external key value store from the Swarm container. For this example, we will use etcd however, you can use any key/value backend supported by Swarm.
docker run \
-ti \
-d \
-p 4001:4001 \
-p 7001:7001 \
--restart=always \
--name shipyard-discovery \
microbox/etcd -name discovery
2.2.3 Proxy
By default, the Docker Engine only listens on a socket. We could re-configure the Engine to use TLS or you can use a proxy container. This is a very lightweight container that simply forwards requests from TCP to the Unix socket that Docker listens on.
Note: You do not need this if you are using a manual TCP / TLS configuration.
docker run \
-ti \
-d \
-p 2375:2375 \
--hostname=$HOSTNAME \
--restart=always \
--name shipyard-proxy \
-v /var/run/docker.sock:/var/run/docker.sock \
-e PORT=2375 \
shipyard/docker-proxy:latest
2.2.4 Swarm Manager
This will run a Swarm container configured to manage.
# 格式
docker run \
-ti \
-d \
--restart=always \
--name shipyard-swarm-manager \
swarm:latest \
manage --host tcp://0.0.0.0:3375 etcd://<IP-OF-HOST>:4001
# 实例
docker run \
-ti \
-d \
--restart=always \
--name shipyard-swarm-manager \
swarm:latest \
manage --host tcp://0.0.0.0:3375 etcd://172.17.0.8:4001
2.2.5 Swarm Agent
官网的坑:
This will run a Swarm container configured to manage.
# 格式
docker run \
-ti \
-d \
--name shipyard-swarm-agent docker.io/swarm join \
--addr [IP-OF-HOST]:[LOCAL-DOCKER-PORT] etcd://[IP-OF-ETCD-HOST]:4001
# 实例
docker run \
-ti \
-d \
--name shipyard-swarm-agent swarm join \
--addr 172.17.0.8:2375 etcd://172.17.0.8:4001
2.2.6 Controller
This runs the Shipyard Controller.
docker run \
-ti \
-d \
--restart=always \
--name shipyard-controller \
--link shipyard-rethinkdb:rethinkdb \
--link shipyard-swarm-manager:swarm \
-p 8080:8080 \
shipyard/shipyard:latest \
server \
-d tcp://swarm:3375
Once the controller is launched and the controller has initialized the datastore you should be able to login via http://[ip-of-host]:8080. User:admin Password:shipyard
2.3 界面展示
登录:
容器管理:
2.4 总结
- 安装步骤较多
- 英文界面不算友好
- 官网有坑