Skip to content
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

removing network-cmd-path from podman configuration #2178

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions libnetwork/slirp4netns/slirp4netns.go
Original file line number Diff line number Diff line change
Expand Up @@ -246,13 +246,10 @@ func createBasicSlirpCmdArgs(options *networkOptions, features *slirpFeatures) (
// Setup can be called in rootful as well as in rootless.
// Spawns the slirp4netns process and setup port forwarding if ports are given.
func Setup(opts *SetupOptions) (*SetupResult, error) {
path := opts.Config.Engine.NetworkCmdPath
if path == "" {
var err error
path, err = opts.Config.FindHelperBinary(BinaryName, true)
if err != nil {
return nil, fmt.Errorf("could not find slirp4netns, the network namespace can't be configured: %w", err)
}
var err error
path, err := opts.Config.FindHelperBinary(BinaryName, true)
if err != nil {
return nil, fmt.Errorf("could not find slirp4netns, the network namespace can't be configured: %w", err)
}

syncR, syncW, err := os.Pipe()
Expand Down
3 changes: 0 additions & 3 deletions pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -393,9 +393,6 @@ type EngineConfig struct {
// containers and pods will be visible. The default namespace is "".
Namespace string `toml:"namespace,omitempty"`

// NetworkCmdPath is the path to the slirp4netns binary.
NetworkCmdPath string `toml:"network_cmd_path,omitempty"`

// NetworkCmdOptions is the default options to pass to the slirp4netns binary.
// For example "allow_host_loopback=true"
NetworkCmdOptions attributedstring.Slice `toml:"network_cmd_options,omitempty"`
Expand Down
4 changes: 0 additions & 4 deletions pkg/config/containers.conf
Original file line number Diff line number Diff line change
Expand Up @@ -628,10 +628,6 @@ default_sysctls = [
#
#namespace = ""

# Path to the slirp4netns binary
#
#network_cmd_path = ""

# Default options to pass to the slirp4netns binary.
# Valid options values are:
#
Expand Down