by dusanh · 2y ago · 0 comments
(dev) $ podman info
ERRO[0000] running `/usr/bin/newuidmap 3427 0 1000 1 1 100000 65536`: newuidmap: open of uid_map failed: Permission denied
Error: cannot set up namespace using "/usr/bin/newuidmap": exit status 1
I tried a solution I found on Red Hat's Customer Portal: (root) # setcap cap_setuid+ep /usr/bin/newuidmap
(root) # setcap cap_setgid+ep /usr/bin/newgidmap
Also did not work. I can run (root) # podman info
just fine as root. This leads me to believe there are some other problems with my non-root user permissions.EDIT: It probably makes little sense, to run rootless on top of an already unprivileged LXC. I just wanted to give vscode server it's own non-root user in there. Oh well...
I used rootless docker in rootless lxc because the Postgres Docker (e.g.) will try to setup a non-root user by default. In a rootless LXC, this means it will try to access very large uids (>100000), which are not available, unless explicitly prepared.
1) Created a new LXC.
2) As root, I created a new user "devel"
3) For the "devel" user set both subuid and subgid to devel:100000:65536
4) As root, installed podman
5) In another SSH session, logged in as "devel" and ran "podman version"
Same error as before. This is in a Debian 12 LXC running on Proxmox.