Loading...
Loading...
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sockYour current user doesn't have permission to access the Docker daemon socket. By default, only root and members of the docker group can communicate with the Docker daemon.
This is the recommended fix — avoids needing sudo for every Docker command.
# Add current user to docker group
sudo usermod - aG docker $USER
# Apply the group change(or log out and back in)
newgrp docker
# Verify it works
docker psPrefix Docker commands with sudo as a temporary fix.
sudo docker ps
sudo docker run hello - world