`podman-compose`/`docker compose` against Podman socket fails: `Cannot connect to the Docker daemon at unix:///var/run/docker.sock`.
IntermediateTroubleshootingSecurity, rootless, Podman and containerd
Answer
Likely causes → Podman API socket isn't enabled or DOCKER_HOST isn't set.
Diagnose → systemctl --user status podman.socket; ls $XDG_RUNTIME_DIR/podman/podman.sock.
Fix →
systemctl --user enable --now podman.socket
export DOCKER_HOST=unix://$XDG_RUNTIME_DIR/podman/podman.sock
Prevent → Set DOCKER_HOST in the shell profile.
More on Security, rootless, Podman and containerd
Rootless Docker: `dockerd-rootless.sh` fails with `newuidmap: write to uid_map failed: Operation not permitted`IntermediateRootless: `rootlesskit: failed to ... listen tcp 0.0.0.0:80: bind: permission denied`BeginnerRootless Docker stops when you log out of SSH.BeginnerRootless containers: `Error: ... cannot set up namespace using "/usr/bin/newuidmap": should have setuid or have filecaps setuid` (Podman).IntermediatePodman: `Error: short-name "nginx" did not resolve to an alias and no unqualified-search registries are defined in "/etc/containers/registries.conf"`BeginnerPodman rootless: `Error: cannot find newuidmap` / ping fails inside container: `ping: permission denied (are you root?)`.Intermediate