Merge pull request #18303 from n1hility/user-mode

Add user-mode networking feature to Windows/WSL
This commit is contained in:
OpenShift Merge Robot
2023-04-26 16:01:48 -04:00
committed by GitHub
19 changed files with 743 additions and 175 deletions

View File

@ -19,7 +19,9 @@ podman-kube-play.1.md
podman-login.1.md
podman-logout.1.md
podman-logs.1.md
podman-machine-init.1.md
podman-machine-list.1.md
podman-machine-set.1.md
podman-manifest-add.1.md
podman-manifest-annotate.1.md
podman-manifest-create.1.md

View File

@ -0,0 +1,21 @@
####> This option file is used in:
####> podman machine init, machine set
####> If file is edited, make sure the changes
####> are applicable to all of those.
#### **--user-mode-networking**
Whether this machine should relay traffic from the guest through a user-space
process running on the host. In some VPN configurations the VPN may drop
traffic from alternate network interfaces, including VM network devices. By
enabling user-mode networking (a setting of `true`), VPNs will observe all
podman machine traffic as coming from the host, bypassing the problem.
When the qemu backend is used (Linux, Mac), user-mode networking is
mandatory and the only allowed value is `true`. In contrast, The Windows/WSL
backend defaults to `false`, and follows the standard WSL network setup.
Changing this setting to `true` on Windows/WSL will inform Podman to replace
the WSL networking setup on start of this machine instance with a user-mode
networking distribution. Since WSL shares the same kernel across
distributions, all other running distributions will reuse this network.
Likewise, when the last machine instance with a `true` setting stops, the
original networking setup will be restored.

View File

@ -76,6 +76,8 @@ Set the timezone for the machine and containers. Valid values are `local` or
a `timezone` such as `America/Chicago`. A value of `local`, which is the default,
means to use the timezone of the machine host.
@@option user-mode-networking
#### **--username**
Username to use for executing commands in remote VM. Default value is `core`

View File

@ -31,6 +31,7 @@ Print results with a Go template.
| .Resources ... | Resources used by the machine |
| .SSHConfig ... | SSH configuration info for communitating with machine |
| .State ... | Machine state |
| .UserModeNetworking | Whether this machine uses user-mode networking |
#### **--help**

View File

@ -32,22 +32,23 @@ Change the default output format. This can be of a supported type like 'json'
or a Go template.
Valid placeholders for the Go template are listed below:
| **Placeholder** | **Description** |
| --------------- | ------------------------------- |
| .CPUs | Number of CPUs |
| .Created | Time since VM creation |
| .Default | Is default machine |
| .DiskSize | Disk size of machine |
| .IdentityPath | Path to ssh identity file |
| .LastUp | Time machine was last up |
| .LastUp | Time since the VM was last run |
| .Memory | Allocated memory for machine |
| .Name | VM name |
| .Port | SSH Port to use to connect to VM|
| .RemoteUsername | VM Username for rootless Podman |
| .Running | Is machine running |
| .Stream | Stream name |
| .VMType | VM type |
| **Placeholder** | **Description** |
| ------------------- | ----------------------------------------- |
| .CPUs | Number of CPUs |
| .Created | Time since VM creation |
| .Default | Is default machine |
| .DiskSize | Disk size of machine |
| .IdentityPath | Path to ssh identity file |
| .LastUp | Time machine was last up |
| .LastUp | Time since the VM was last run |
| .Memory | Allocated memory for machine |
| .Name | VM name |
| .Port | SSH Port to use to connect to VM |
| .RemoteUsername | VM Username for rootless Podman |
| .Running | Is machine running |
| .Stream | Stream name |
| .UserModeNetworking | Whether machine uses user-mode networking |
| .VMType | VM type |
#### **--help**

View File

@ -40,6 +40,8 @@ container execution. This option will also update the current podman
remote connection default if it is currently pointing at the specified
machine name (or `podman-machine-default` if no name is specified).
@@option user-mode-networking
Unlike [**podman system connection default**](podman-system-connection-default.1.md)
this option will also make the API socket, if available, forward to the rootful/rootless
socket in the VM.