Make sure that var/run/docker.sock is pointing to the running docker socket. You can do this by ls -l /var/run/docker.sock.
var/run/docker.sock
ls -l /var/run/docker.sock
In my case this was pointing to podman while I was running colima
podman
colima