08、Docker图形页面管理-Portainer

2019-05-16  本文已影响0人  六弦极品

Portainet 是一个开源、轻量级Docker管理用户界面,基于Docker API,可管理Docker主机或Swarm集群,支持最新版Docker和Swarm模式
https://www.portainer.io/installation/

1、创建卷

# docker volume create portainer_data

2、启动Portainert容器

直接从官方下载镜像启动:

# docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer
Unable to find image 'portainer/portainer:latest' locally
latest: Pulling from portainer/portainer
d1e017099d17: Pull complete 
0b1e707a06d2: Pull complete 
Digest: sha256:babbd30e81ef22bc463fb7093cfb32da4799d8b75663e675d47f36d8ecd29b5e
Status: Downloaded newer image for portainer/portainer:latest
a82b4b6c0fca99632f7720c3c05ce333043f1478fb031e3cc36a428a1e13e76f

可以先从官方下载镜像然后提交到我们自己部署的harbor 镜像仓库,让后harbor仓库拉取镜像启动容器

# docker pull portainer/portainer
Using default tag: latest
latest: Pulling from portainer/portainer
d1e017099d17: Already exists 
0b1e707a06d2: Pull complete 
Digest: sha256:5702df0ee639d9e003eee626d905e7d4d7ee1a2c7d40a7ec961e3996924f0285
Status: Downloaded newer image for portainer/portainer:latest

# docker tag portainer/portainer 10.40.6.165/library/portainer:v1
# docker push 10.40.6.165/library/portainer:v1
The push refers to repository [10.40.6.165/library/portainer]
e7260fd2a5f2: Pushed 
dd4969f97241: Pushed 
v1: digest: sha256:5702df0ee639d9e003eee626d905e7d4d7ee1a2c7d40a7ec961e3996924f0285 size: 739

# docker run -d --name portainer -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data 10.40.6.165/library/portainer:v1
db8e762c7c914e1d13f6f166b513e468cbe04dc0e126dd277528438984f2ba66
# docker ps -l
CONTAINER ID        IMAGE                              COMMAND             CREATED             STATUS              PORTS                    NAMES
db8e762c7c91        10.40.6.165/library/portainer:v1   "/portainer"        4 seconds ago       Up 3 seconds        0.0.0.0:9000->9000/tcp   portainer

浏览器访问:10.40.6.165:9000


登录管理员密码.png

首先管理Local 本机

上一篇 下一篇

猜你喜欢

热点阅读