In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
Editor to share with you how to use Docker graphical management and monitoring Portainer, I believe most people do not know much about it, so share this article for your reference, I hope you will learn a lot after reading this article, let's go to know it!
Step1: introduction
Portainer is a graphical management tool of Docker, which provides status display panel, rapid deployment of application templates, basic operations of container mirroring network data volumes (including uploading / downloading images, creating containers, etc.), event log display, container console operations, centralized management and operations such as Swarm clusters and services, login user management and control, etc. The function is very comprehensive, which can basically meet all the needs of small and medium-sized units for container management.
Step2: start the service
[root@qa-redis-03 ansible] # docker search portainer # query which Portainer images are currently available
[root@qa-redis-03 ansible] # more portainer.sh # View startup script
Docker run-d-p 9000:9000--restart=always-v / var/run/docker.sock:/var/run/docker.sock-v/etc/ansible/portainer_data:/data-- name prtainer-test portainer/portainer
Command description:
-d indicates that the service is running in the background
-p 9000 means to map the service port 9000 in the container to 9000 on the host machine
The restart strategy of the restart=always container is to always restart the container when it exits.
-v/var/run/docker.sock:/var/run/docker.sock: mounts the Unix domain socket listened to by default by the Docker daemon (Dockerdaemon) of the host to the container
-v portainer_data:/data: Mount host portainer_data data volume to container / data directory
-- name prtainer-test means to set a name for the container to make it easy to identify
Portainer/portainer indicates the name of the image. It must be written correctly here, otherwise the image will not be obtained and the startup will fail.
[root@qa-redis-03 ansible] # shportainer.sh # start the image service
Remarks:
This command will first pull the corresponding image from the local (local) image library. If it cannot be found in the local repository, it will be pulled from the online image repository center.
Step3: verify that the container is running properly
Step4: log in to create and configure
Set the login password for admin
Choose how to connect to the docker
There are four choices here: 1. Connect locally. two。 Connect to other remote machines [this is chosen in this example]. 3. The agent that connects to the Portainer. 4. Connect to Microsoft's cloud environment.
There is a hole here: when you connect to Remote, the remote node machine does not expose the port of 2375, so it will report a "portainer failure unable to ping docker environment" error when connecting, solution:
Cd / etc/systemd/system
Modify the ExecStart as follows:
ExecStart=/opt/kube/bin/dockerd-H unix:///var/run/docker.sock-Htcp://0.0.0.0:2375
Finally:
Systemctl daemon-reload
Systemctl restart docker
Just connect again.
Step5: log in to the remote node and show as follows
The above is all the contents of the article "how to use Portainer for Docker graphical Management and Monitoring". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.