Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

分享:启用Docker远程API #55

Open
woodongwong opened this issue Apr 22, 2021 · 1 comment
Open

分享:启用Docker远程API #55

woodongwong opened this issue Apr 22, 2021 · 1 comment

Comments

@woodongwong
Copy link
Owner

Docker API支持2种方式,Unix domain socket 和 TCP,默认TCP方式是关闭的,此文描写了如何开启Docker TCP API。

Link:https://blog.usejournal.com/how-to-enable-docker-remote-api-on-docker-host-7b73bd3278c6

补充:评论中有一个「完美」解决方案,同时支持这2种方式:

ExecStart=/usr/bin/dockerd -H fd:// -H 0.0.0.0:2375 --containerd=/run/containerd/containerd.sock
@woodongwong
Copy link
Owner Author

woodongwong commented Jun 3, 2021

更新docker后,/lib/systemd/system/docker.service 会恢复成默认内容,需要重新设置。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant