I'm trying to run the Docker Compose version command on my Raspberry Pi 5 with Debian 13.3 without using sudo. I followed the installation instructions, including adding myself to the Docker group using `sudo usermod -aG docker $USER`. However, I still can't execute the command without sudo. Can anyone help me troubleshoot this issue?
3 Answers
Make sure to log out and then log back in after adding yourself to the Docker group. This refreshes your group permissions. You could also use `newgrp docker` if you want to avoid a full logout.
You could also try just using the `newgrp docker` command, which might work faster for you.
Could you share what error message you’re getting? That might help pinpoint the issue better.
I'm getting 'docker: unknown command: docker compose' when I try to run it.
Make sure you've installed the official Docker engine and CLI correctly. You can do this with `wget -qO- https://get.docker.com/ | sudo sh`. Remember to add yourself to the Docker group afterward, but you need to log out for that to take effect.
You can't run `usermod -aG docker $USER` with sudo because it gives a permission denied error. Make sure you're executing it properly.

I actually restarted my Raspberry Pi instead of logging out. Didn't seem to help.