Rootless Docker issues on DietPi

it’s not about permission of the script. It’s the script not being able to detect systemd.

@DietMeow I found an issue at Docker GitHub. dockerd-rootless-setuptool.sh install fails to detect systemd unless $XDG_RUNTIME_DIR is set first · Issue #14491 · docker/docs · GitHub

You need to set export XDG_RUNTIME_DIR=/run/user/$(id -u) before executing the install script.

This one should do it

as user root

dietpi-software install 162
systemctl disable --now docker.service docker.socket
apt install -y uidmap dbus-user-session fuse-overlayfs slirp4netns docker-ce-rootless-extras
systemctl enable --now dbus
loginctl enable-linger <your-user>

as non-root user

export XDG_RUNTIME_DIR=/run/user/$(id -u)
dockerd-rootless-setuptool.sh install
2 Likes