假设我创建了一个命名卷
podman volume create --opt type=cifs --opt o=async --opt device=//mynas.lan/steamcache steamcache
根据podman volume inspect
,该卷的挂载点是
/home/me/.local/share/containers/storage/volumes/steamcache/_data
因此,为了允许在没有 root 权限的情况下安装它,我将其添加到/etc/fstab
:
//mynas.lan/steamcache /home/me/.local/share/containers/storage/volumes/steamcache/_data cifs noauto,user 0 0
当我手动安装它时,这有效:
mount /home/me/.local/share/containers/storage/volumes/steamcache/_data
它要求我输入 smb 密码,然后正确安装文件夹,而无需升级权限。
但是,当我启动使用此卷的 podman 容器时,它会询问我 smb 密码,然后说
Error: error mounting volume steamcache for container 49da929a55753c244cae62244c2bb5417013a37785667d1d138026a4e1d48163: mount error(1): Operation not permitted
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)
mount: permission denied (are you root?)
我在这里做错了什么?