-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
D-in-D with VSCode remote development is broken on 5.3.2 #25153
Comments
The new machine VM images are based on fedora coreos. The latest update is now based on fedora 41 and there we switched podman over to use nftables by default, https://fedoraproject.org/wiki/Changes/NetavarkNftablesDefault. As such we no longer use the old ip tables modules so they are no longer loaded on the host. |
@Luap99 Thank your for the explanation. Makes sense and the trend towards nftables is well know. However, I'm not entirely certain if simply changing the kernel and suggesting users to enable missing features is the right way. Especially in the context of docker desktop where user expertise is very different. Keeping legacy is certainly not always the best approach, but I'd expect changes like that to be done between major releases and well covered in the release notes. With a clear migration plan. Is there any clear guide explaining how to use D-in-D on Podman with the new kernel? Open for any other opinions. |
Well first of all the machine os image is managed separately from podman. We do not have resources to maintain an entire OS distribution so we build on top of fedora coreos, then we just our our own up to date podman rpm on top with some other customizations. As such it is really hard for us to catch changes like this and yes I wrote the change for fedora and I also maintain part of the machine-os image. You cannot expect there to be no breaking changes in the image when it bumps to the next major fedora version. Sure we can/should work on documenting such change when it happen in the release notes.
Is there a guide from us to use podman and vscode to begin with? I am not sure anyone from us actually uses and test that. If there are volunteers to write such thing I am sure they can write that. You don't list the actual error so I don't what exactly the problem is, if it is iptables complaining about not being able to use/load the legacy module then this is expected as the container is not allowed to load the kernel module.
We can certainly consider adding the modules-load file for the ip_tables module back into the machine os. podman/netavark can keep using nftables and since docker runs inside their own container (netns) there should be no firewall conflicts in such case. |
Understood and agreed. Long term the issue must be fixed on VSCode side to make sure that new kernels are respected.
With all that said, I have to admit that this use case is a bit weird, as we are trying to start docker in podman in the first place. But it could be quite common nevertheless due various dev tools and growing podman community. Regarding the errors. $ /usr/local/share/docker-init.sh
Not setting dockerd DNS manually.
(*) Failed to start docker, retrying...
Not setting dockerd DNS manually.
(*) Failed to start docker, retrying...
Not setting dockerd DNS manually.
(*) Failed to start docker, retrying...
Not setting dockerd DNS manually.
(*) Failed to start docker, retrying...
Not setting dockerd DNS manually. The script is relying on $ docker info
Client:
Version: 27.0.3-1
Context: default
Debug Mode: false
Plugins:
buildx: Docker Buildx (Docker Inc.)
Version: v0.18.0
Path: /usr/libexec/docker/cli-plugins/docker-buildx
compose: Docker Compose (Docker Inc.)
Version: 2.30.3-1
Path: /usr/libexec/docker/cli-plugins/docker-compose
Server:
ERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
errors pretty printing info When unmuted, script provides some clues:
After loading ip_tables docker starts successfully, although according to the warnings some nice-to-have modules are probably still missing:
PS: thx for maintaining a great product! |
containers/podman-machine-os#71
That is far out of scope for us. Our CI pipeline is already gigantic and we are already only testing podman itself. Testing if third party applications work or not in our pipeline is simply not maintainable for us.
In general there are two iptables packages
I am not aware any actual documentation around this. But our image build process is totally open so anyone can have a look there: https://github.com/containers/podman-machine-os
ip6_tables is needed as well. That was the only two modules the we (podman) at least dropped from being loaded by default. |
containers/podman-machine-os@c0e59d0
Issue Description
We are using D-in-D with Podman Desktop rootful machine. It worked great with podman 5.3.1. However it's breaking on 5.3.2.
sudo modprobe ip_tables
on podman machine fixes the problem. I'd expect it's somehow related to the kernel change, however can't find any clues in 5.3.2 release notes.The problem is easy to reproduce. 1st, start any devcontainer. Normally VSCode will be used for that, but it's easier to spot errors on CLI.
Next, init docker inside the container using Microsoft script:
This will fail with error and
docker info
will be complaining that docker is not running.As a workaround:
This will fix the problem, although some iptables errors will be still reported in logs.
Here is the full script for convenience:
Steps to reproduce the issue
Steps to reproduce the issue
docker info
will fail as well.Describe the results you received
D-in-D is failing on 5.3.2
Describe the results you expected
Expect D-in-D to work
podman info output
Podman in a container
No
Privileged Or Rootless
Privileged
Upstream Latest Release
Yes
Additional environment details
Additional environment details
Additional information
Additional information like issue happens only occasionally or issue happens with a particular architecture or on a particular setting
The text was updated successfully, but these errors were encountered: