Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Implementation of remote access enabled by Docker

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

There is such a requirement, when I need to deploy the docker container through the mvn package docker:build of eclipse, we are in a window environment, so we need a remote docker to deploy the service.

Open the / usr/lib/systemd/system/docker.service file and modify the line ExecStart.

Vim / usr/lib/systemd/system/docker.serviceExecStart=/usr/bin/dockerd-H tcp://0.0.0.0:2375-H unix:///var/run/docker.sock# reload configuration file systemctl daemon-reload # restart service systemctl restart docker.service # check whether the port is open netstat-nptl# Direct curl to see if it works curl http://127.0.0.1:2375/info

Enable remote access

View port information after reboot

Direct access port

Reference article

Https://www.jb51.net/article/141213.htm

The above is the whole content of this article, I hope it will be helpful to your study, and I also hope that you will support it.

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.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report