-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
podman machine improve port forwarding #12283
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Luap99 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
852898d
to
0ba4e65
Compare
lgtm removing the podman-machine-cni binary is a great idea! |
LGTM |
Is there a chance having an old VM with a recent podman on the host won't work? If the VM image with newer podman is released after podman on the Mac, could it happen? |
It's not so obvious how to tunnel an arbitrary port (e.g. 9090) over to the VM, like which podman command to use. |
Port forwarding is done automatically for your containers. There is no podman command for that. If you need to expose arbitrary ports you need to talk directly to gvproxy. |
Yes this will be a problem. Given that this is a 4.0 change we have to update both at the same time otherwise you run into many issues, the libpod API is not compatible. |
This commits adds port forwarding logic directly into podman. The podman-machine cni plugin is no longer needed. The following new features are supported: - works with cni, netavark and slirp4netns - ports can use the hostIP to bind instead of hard coding 0.0.0.0 - gvproxy no longer listens on 0.0.0.0:7777 (requires a new gvproxy version) - support the udp protocol With this we no longer need podman-machine-cni and should remove it from the packaging. There is also a change to make sure we are backwards compatible with old config which include this plugin. Fixes containers#11528 Fixes containers#11728 [NO NEW TESTS NEEDED] We have no podman machine test at the moment. Please test this manually on your system. Signed-off-by: Paul Holzinger <[email protected]>
0ba4e65
to
295d87b
Compare
My two-cents
|
Added labels and more info to the PR description.
There is no point in supporting that, the 4.X client should/will refuse to work with an 3.X server. The API is not compatible so there is no point is supporting the the 7777 port for the old server. The latest gvproxy release already contains this feature so we should be good, podman 4.0 will not be released for another 2-3 months. |
/lgtm |
This PR contains a fix to the CVE-2021-4024 Vulnerability description: |
What this PR does / why we need it:
This commits adds port forwarding logic directly into podman. The
podman-machine cni plugin is no longer needed.
The following new features are supported:
version), the API is only reachable from within the VM via
gateway.containers.internal
With this we no longer need podman-machine-cni and should remove it from
the packaging. There is also a change to make sure we are backwards
compatible with old config which include this plugin.
How to verify it
We have no podman machine test at the moment.
Please test this manually on your system.
Make sure to copy the new podman and rootlessport binary into the vm
because the server needs the fix. Also make sure your gvproxy is new enough.
Which issue(s) this PR fixes:
Fixes #11528
Fixes #11728
Special notes for your reviewer: