在Ubuntu或者Debian已经部署完毕Docker
拉取镜像文件:
$ docker pull docker.io/portainer/portainer Using default tag: latest latest: Pulling from portainer/portainer d1e017099d17: Pull complete 8ca27898abd9: Pull complete Digest: sha256:166ea71afde944c36758bbe42389d18c100f431fe72aacdc2e8c32ae9d9f0535 Status: Downloaded newer image for portainer/portainer:latest
Deploy Portainer
Use the following Docker commands to deploy Portainer:
$ docker volume create portainer_data $ docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer
在debian执行过程如下:
[email protected]:~# docker pull docker.io/portainer/portainer Using default tag: latest latest: Pulling from portainer/portainer d1e017099d17: Pull complete 8ca27898abd9: Pull complete Digest: sha256:166ea71afde944c36758bbe42389d18c100f431fe72aacdc2e8c32ae9d9f0535 Status: Downloaded newer image for portainer/portainer:latest [email protected]:~# docker volume create portainer_data portainer_data [email protected]:~# docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer 5a9e7c4d7e1be0e1262fb255162a14608dbc54c8ca5c98ed492dfe4510913b35
portainer的镜像文件17M多。
浏览器输入http://192.168.0.2:9000,回车,跳转到初始化界面http://192.168.0.153:9000/#/init/admin
创建管理员用户名和密码,密码需要8位,点击Create user创建用户
下一个界面选择local本地运行吧。connect连接
写教程时安装版本位1.18.1
原文地址:https://www.cnblogs.com/arrive/p/9298339.html
时间: 2024-11-08 08:53:43