You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reacted by Maxim Schuwalow, Chris Balmer, frostspanner, Sean Jones, gui-bo, hebrewd, Micah Abbott, Hofer-Julian, Humberto Pires Marques, Steven Taylor and 120 more
Reacted by Dario Tislar, Vincent Batts, Ondřej Míchal, gabichan, Stefan Geiger, Marek Kaput, Hergeirs, Antony den Dulk, Oahz Egroeg, Thorsten Scherf and 15 more
Well friends after the latest release of Fedora more and more people need this support. Please make it happen for us humble devs.
Reacted by Antony den Dulk, Niki, Nicola Erario, Alessandro Bernardi, Muhammad Ahmad, Nikolaj Janko, Eveline Raine, Tuomas Mäkinen, C. Daniel Eguia, yannlawrency and 45 more
Reacted by Hergeirs, Oahz Egroeg, Peter, Jacob Henner, A1pen, Ondřej Míchal, 🌟 Mundo DevOps 🌟, Christoph Roeper and Stefan Geiger
Not having to make my system easily compromisable by having docker run with root privileges is awesome, that is what Podman gives us. Now, also being able to use tooling that works with this superior way, would be even greater.
Reacted by Jacob Henner, Jonas SPRENGER, juhyun210, Alessandro Bernardi, Daniel, Judah Rand, Vegar Ringdal, Jeffrey Serio, Herbert Rusznak, gotbeer and 2 more
There is a package on certain OS that basically makes the docker CLI work via emulation (under the covers it's podman). However, at present it appears that VSCode does some kind of check to validate what version of the docker runtime is installed.
"Docker version 17.06.1 or later required"
Maybe we could just add a switch to the plugin to enable validation of Podman's version output. Let me poke at the code here...
Reacted by Lena Schönburg, Jacob Henner, Yun Hao and Qx ElleJay
The main issue is that the extension wants to talk to Docker via its socket, which Podman does not implement currently, although they are working on it: podman-container-tools/podman#4499
Jairo Llopis (@yajo) This is already in libpod as "alpha". Libpod 1.8.1 was released yesterday, and it has updated the HTTP API to add some new features and fix some bugs. See this link for more information.
One thing is breaking for me when running rootless podman, using a dev container image with non-root user: the postCreateCommand fails to execute when building a fresh dev container, and the result seems to be file permission issue: running touch in the workspace directory results in a Permission denied error. Anyone has clues how to fix this? Thanks.
Seems relevant: podman-container-tools/podman#2898. It's likely the remote container plugin needs to pass different CLI flags to podman to set this up properly.
Cheng Shao (@TerrorJack) For me this seemed to be a SELinux issue. You can disable SELinux by passing a flag to podman as a run arg. This can be done by adding "runArgs": [ "--security-opt", "label=disable" ] to devcontainer.json.
It's already fixed in podman-container-tools/podman#6091 upstream but at least on my machine that build isn't returning anything from podman info so this is very much a WIP.
However, certain tricks like Docker-in-Docker do not work due to limitations in Podman. This affects the Remote-Containers: Try a Sample... and Remote- Containers: Open repository in container... commands.
Cheng Shao (@TerrorJack)smekkley Could you open an issue with brief steps to reproduce the rootless problem? VS Code doesn't need to run as root, but we might still be missing some details with Podman.
Thanks for the reply. I was looking for up-to-date information. The documentation says it has a partial support for podman and I saw this issue was closed, so I thought that what I quoted from the documentation is outdated. With my version, I still have to create symlink to docker. Maybe it's fixed on next release?
Fedora doesn't come with docker, so it'd be great if there is a git issue to handle this. This git issue seems to have a perfect title.
As podman experimentally supports tcp socket, vscode can be used for remote containers as well, if it supports it directly.
One of the use cases would be that you can have one super powerful machine and run rootless podman socket for each user and everyone can have isolated environment.
When you mention it, I assume that podman supports specifying the socket, so that you can use command line the same way. AFAIK, it's possible through podman remote through ssh. If it's not possible with new podman socket, podman should support it otherwise.
and then podman in podman solution might be possible by mounting the socket, but for that vscode sample containers feature and etc have to support modifying the podman command line option a little both in and outside the container, and in case of sample docker images, it needs to have podman client.
OK. Thanks. But I think we can conclude that the following is not solved yet for anyone who come across this issue.
However, certain tricks like Docker-in-Docker do not work due to limitations in Podman. This affects the Remote-Containers: Try a Sample... and Remote- Containers: Open repository in container... commands.
Docker-in-Docker configuration is officially supported by the Docker because there is an official docid image in the repository called Docker. I think it is right to ask RedHat via GithubHub about official Podma-in-Podman or Podman-in-Docker images. There are too many combinations to check in blind.
Activity
Edits based on customer feedback
paul8046 commentedon Aug 5, 2019
Ideally all OCI container utilities would be supported. podman, for example, is the default utility for Fedora Silverblue.
[-]podman support when? [/-][+]Podman support[/+]spgennard commentedon Oct 9, 2019
On the top of the this, "Red Hat 8, Oracle Linux 8" all default to using OCI/podman by default.
efeozazar commentedon Nov 1, 2019
Well friends after the latest release of Fedora more and more people need this support. Please make it happen for us humble devs.
mario-d-s commentedon Nov 15, 2019
Not having to make my system easily compromisable by having docker run with root privileges is awesome, that is what Podman gives us. Now, also being able to use tooling that works with this superior way, would be even greater.
thoraxe commentedon Feb 20, 2020
There is a package on certain OS that basically makes the
dockerCLI work via emulation (under the covers it'spodman). However, at present it appears that VSCode does some kind of check to validate what version of thedockerruntime is installed."Docker version 17.06.1 or later required"
Maybe we could just add a switch to the plugin to enable validation of Podman's version output. Let me poke at the code here...
chrmarti commentedon Feb 21, 2020
Bumped into podman-container-tools/podman#5046 while exploring this. We would need that fixed to run our existing code with the Podman CLI.
Erik Jacobs (@thoraxe) What package on which OS? Maybe we can change the check on our side to enable this.
mario-d-s commentedon Feb 22, 2020
The main issue is that the extension wants to talk to Docker via its socket, which Podman does not implement currently, although they are working on it: podman-container-tools/podman#4499
chrmarti commentedon Mar 9, 2020
I have removed the dependency on dockerode, so we can run with the CLI alone (#2481).
When trying to attach to an existing container, it now fails due to podman-container-tools/podman#5046 when trying to copy the server bits over.
yajo commentedon Mar 12, 2020
You might find these news interesting: https://podman.io/blogs/2020/01/17/podman-new-api.html
tl;dr: you will be able soon to use Docker API to interact with podman.
nimashoghi commentedon Mar 12, 2020
Jairo Llopis (@yajo) This is already in libpod as "alpha". Libpod 1.8.1 was released yesterday, and it has updated the HTTP API to add some new features and fix some bugs. See this link for more information.
16 remaining items
TerrorJack commentedon May 8, 2020
According to https://github.com/microsoft/vscode-docs/blob/master/remote-release-notes/v1_45.md#podman-support, we only need to set up
dockeras a symlink topodman.One thing is breaking for me when running rootless
podman, using a dev container image with non-root user: thepostCreateCommandfails to execute when building a fresh dev container, and the result seems to be file permission issue: runningtouchin the workspace directory results in aPermission deniederror. Anyone has clues how to fix this? Thanks.Seems relevant: podman-container-tools/podman#2898. It's likely the remote container plugin needs to pass different CLI flags to
podmanto set this up properly.angusgyoung commentedon May 8, 2020
Cheng Shao (@TerrorJack) For me this seemed to be a SELinux issue. You can disable SELinux by passing a flag to podman as a run arg. This can be done by adding
"runArgs": [ "--security-opt", "label=disable" ]todevcontainer.json.cryobry commentedon May 8, 2020
Once you get past that error you'll run into podman-container-tools/podman#6083 when you attempt to launch a remote container.
It's already fixed in podman-container-tools/podman#6091 upstream but at least on my machine that build isn't returning anything from
podman infoso this is very much a WIP.smekkley commentedon May 10, 2020
Does anybody know if the following issue is solved on next release?
https://code.visualstudio.com/docs/remote/containers
It's not cool that vscode gaining full root in case vscode and rootful docker is running on linux.
The latest podman also support api socket as well.
https://github.com/containers/libpod/blob/v1.9.1/docs/source/markdown/podman-system-service.1.md
chrmarti commentedon May 11, 2020
Cheng Shao (@TerrorJack) smekkley Could you open an issue with brief steps to reproduce the rootless problem? VS Code doesn't need to run as root, but we might still be missing some details with Podman.
smekkley commentedon May 11, 2020
Thanks for the reply. I was looking for up-to-date information. The documentation says it has a partial support for podman and I saw this issue was closed, so I thought that what I quoted from the documentation is outdated. With my version, I still have to create symlink to docker. Maybe it's fixed on next release?
Fedora doesn't come with docker, so it'd be great if there is a git issue to handle this. This git issue seems to have a perfect title.
As podman experimentally supports tcp socket, vscode can be used for remote containers as well, if it supports it directly.
One of the use cases would be that you can have one super powerful machine and run rootless podman socket for each user and everyone can have isolated environment.
chrmarti commentedon May 12, 2020
smekkley The next release will have a setting where you can configure the name or path of a Docker-compatible CLI. (#2887)
Remote-Containers does not rely on the tcp socket anymore, it uses only the CLI. Can the CLI be used to achieve the per-user isolation you suggest?
smekkley commentedon May 13, 2020
When you mention it, I assume that podman supports specifying the socket, so that you can use command line the same way. AFAIK, it's possible through podman remote through ssh. If it's not possible with new podman socket, podman should support it otherwise.
and then podman in podman solution might be possible by mounting the socket, but for that vscode sample containers feature and etc have to support modifying the podman command line option a little both in and outside the container, and in case of sample docker images, it needs to have podman client.
chrmarti commentedon May 14, 2020
smekkley Still working on my Podman expertise, could you open a feature request with more details on how to achieve this?
smekkley commentedon May 14, 2020
OK. Thanks. But I think we can conclude that the following is not solved yet for anyone who come across this issue.
PavelSosin-320 commentedon May 14, 2020
Docker-in-Docker configuration is officially supported by the Docker because there is an official docid image in the repository called Docker. I think it is right to ask RedHat via GithubHub about official Podma-in-Podman or Podman-in-Docker images. There are too many combinations to check in blind.
chrmarti commentedon May 15, 2020
smekkley We are tracking that as #2881.
yajo commentedon May 15, 2020
You can install
podman-dockerin Fedora 32.#2887 seems already fixed.
Upstream issue: podman-container-tools/podman#6219
smekkley commentedon May 15, 2020
Thanks for all the responses. You guys are the most helpful IDE developers.