-
Notifications
You must be signed in to change notification settings - Fork 6.3k
How to get Docker ClI working in Code Server? #7151
-
I have not been able to "install" or get docker cli working from within code server.
I primarily use vs code for docker development and am stuck unable to get even a "docker ps" working. I just get errors saying
"Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?"
What's the best way to get docker cli into code server?
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 2 comments 2 replies
-
Are you running code-server in a Docker container and want it to access the host Docker instance? I think you can make this work if you mount /var/run/docker.sock
. Such as docker run -v /var/run/docker.sock:/var/run/docker.sock codercom/code-server
.
Beta Was this translation helpful? Give feedback.
All reactions
-
I am running it in a Docker container and I did get that to work previosuly, however I was hoping to install a standalone docker instance within the container (but I'm guessing that's not possible). So I created a standalone VM in Proxmox for just Code Server and passing through just like you listed.
Beta Was this translation helpful? Give feedback.
All reactions
-
Ah, so you want a separate Docker inside Docker rather than controlling the host Docker? I believe this is possible but you will have to use a privileged container and use the docker:dind
image (or base your image off it). https://hub.docker.com/_/docker
Beta Was this translation helpful? Give feedback.
All reactions
-
With b-data's/my Jupyter Lab docker stacks 1 , I prefer using a docker:dind
container.
Cross reference:
Footnotes
-
subtag
docker
: includesdocker-ce-cli
,docker-buildx-plugin
,docker-compose-plugin
anddocker-scan-plugin
(amd64 only) ↩
Beta Was this translation helpful? Give feedback.