Merge pull request #22177 from mheon/fix_22172

Add rootless network command to `podman info`
This commit is contained in:
openshift-merge-bot[bot] 2024-03-26 17:15:53 +00:00 committed by GitHub
commit 25ebf10967
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 6 additions and 2 deletions

View File

@ -52,6 +52,8 @@ type HostInfo struct {
OS string `json:"os"`
// RemoteSocket returns the UNIX domain socket the Podman service is listening on
RemoteSocket *RemoteSocket `json:"remoteSocket,omitempty"`
// RootlessNetworkCmd returns the default rootless network command (slirp4netns or pasta)
RootlessNetworkCmd string `json:"rootlessNetworkCmd"`
RuntimeInfo map[string]interface{} `json:"runtimeInfo,omitempty"`
// ServiceIsRemote is true when the podman/libpod service is remote to the client
ServiceIsRemote bool `json:"serviceIsRemote"`

View File

@ -126,6 +126,7 @@ func (r *Runtime) hostInfo() (*define.HostInfo, error) {
NetworkBackend: r.config.Network.NetworkBackend,
NetworkBackendInfo: r.network.NetworkInfo(),
OS: runtime.GOOS,
RootlessNetworkCmd: r.config.Network.DefaultRootlessNetworkCmd,
SwapFree: mi.SwapFree,
SwapTotal: mi.SwapTotal,
}

View File

@ -47,6 +47,7 @@ host.cgroupVersion | v[12]
host.networkBackendInfo | .*dns.*package.*
host.ociRuntime.path | $expr_path
host.pasta | .*executable.*package.*
host.rootlessNetworkCmd | pasta
store.configFile | $expr_path
store.graphDriverName | [a-z0-9]\\\+\\\$
store.graphRoot | $expr_path