群晖 DSM7.X docker 启动权限不足问题解决方案

619次阅读
没有评论

共计 624 个字符,预计需要花费 2 分钟才能阅读完成。

群晖更新DSM 7 之后 docker 无法启动,特记录问题及解决方案。

问题症状

docker 启动报错:

PermissionError: [Errno 13] Permission denied: 'config.ini'

问题原因

权限不足。

解决方案

设置 PUID,PGID:

群晖 DSM7.X docker 启动权限不足问题解决方案

首先是PGID,和PUID。Docker Hub readme中解释了如何查看。

User / Group Identifiers

When using volumes (-v flags) permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user PUID and group PGID.

Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.

In this instance PUID=1000 and PGID=1000, to find yours use id user as below:

$ id username
uid=1000(dockeruser) gid=1000(dockergroup) groups=1000(dockergroup)

gid一般100是普通用户组,101是管理员组。设置成100有时候会没权限,所以设成101。

正文完
点击链接加入群聊【轩源技术交流群】:https://qm.qq.com/q/xrQ0LCYwTe
post-qrcode
 0
轩源
版权声明:本站原创文章,由 轩源 于2023-03-25发表,共计624字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
支持作者

☝️用微信请我喝杯咖啡☕️

😛如果文章对您有用,请支持作者😛

支持作者

☝️用支付宝请我喝杯奶茶🧋

评论(没有评论)