C
Coder.com•2y ago
Zaserr

Docker error

Error: Error pinging Docker server: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get "http://%2Fvar%2Frun%2Fdocker.sock/_ping": dial unix /var/run/docker.sock: connect: permission denied
15 Replies
Phorcys
Phorcys•2y ago
you have to run coder server as coder:998
Zaserr
Zaserr•2y ago
How do I do that?
Phorcys
Phorcys•2y ago
actually, you can probably just do usermod -aG coder docker since you're not running coder in docker
Zaserr
Zaserr•2y ago
I am getting user 'docker' does not exist
Phorcys
Phorcys•2y ago
swap coder and docker usermod -aG docker coder
Zaserr
Zaserr•2y ago
I did that and tried to create the docker template
Zaserr
Zaserr•2y ago
No description
Phorcys
Phorcys•2y ago
what user are you running the command as wait no i don't know i'll take a look later
Zaserr
Zaserr•2y ago
Root 😊 Anyone know the fix? haha I am soo lost
Phorcys
Phorcys•2y ago
I think you should add Group=docker to your service file (or replace existing group definition) docker and coder run on the same machine correct?
Zaserr
Zaserr•2y ago
Yes
Phorcys
Phorcys•2y ago
yeah that shoud work then
Zaserr
Zaserr•2y ago
Where is the service file?
Phorcys
Phorcys•2y ago
the path ending in .service when running systemctl status coder
Zaserr
Zaserr•2y ago
Thank you this fixed it.
Want results from more Discord servers?
Add your server