gpt4 book ai didi

linux - 使用 root 以外的用户启动 Docker 守护程序时出错(权限被拒绝)

转载 作者:太空宇宙 更新时间:2023-11-04 10:29:27 24 4
gpt4 key购买 nike

我想用 root 以外的用户启动 Docker 守护进程。

我正在尝试使用 docker daemon --host=unix:///var/run/docker.sock --host=tcp://0.0.0.0:2375 --storage-driver 启动它=vfs.

遗憾的是发生了这个错误:

FATA[0000] Error starting daemon: open /var/run/docker.pid: permission denied

当我查看目录 /var/run/ 时,我看不到任何名为docker.pid.

root 身份启动服务没有问题。

最佳答案

Docker 守护进程必须以 root 身份运行。

编辑:https://docs.docker.com/engine/security/security/#/docker-daemon-attack-surface

关于linux - 使用 root 以外的用户启动 Docker 守护程序时出错(权限被拒绝),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40585910/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com