diff options
author | Paul Holzinger <pholzing@redhat.com> | 2021-11-11 16:37:13 +0100 |
---|---|---|
committer | Paul Holzinger <pholzing@redhat.com> | 2021-11-11 17:30:27 +0100 |
commit | fe90a45e0d914723b8c26e4e9497f414312b6af0 (patch) | |
tree | 883c28f2c52c6a2c6e01848efd7ca763216ddf2c /pkg/domain/infra | |
parent | 8041d44c93ac46d330325cda849716f5ba2c40d9 (diff) | |
download | podman-fe90a45e0d914723b8c26e4e9497f414312b6af0.tar.gz podman-fe90a45e0d914723b8c26e4e9497f414312b6af0.tar.bz2 podman-fe90a45e0d914723b8c26e4e9497f414312b6af0.zip |
Add flag to overwrite network backend from config
To make testing easier we can overwrite the network backend with the
global `--network-backend` option.
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'pkg/domain/infra')
-rw-r--r-- | pkg/domain/infra/runtime_libpod.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkg/domain/infra/runtime_libpod.go b/pkg/domain/infra/runtime_libpod.go index 7ec6135ee..cfb674b6d 100644 --- a/pkg/domain/infra/runtime_libpod.go +++ b/pkg/domain/infra/runtime_libpod.go @@ -200,6 +200,9 @@ func getRuntime(ctx context.Context, fs *flag.FlagSet, opts *engineOpts) (*libpo if fs.Changed("network-cmd-path") { options = append(options, libpod.WithNetworkCmdPath(cfg.Engine.NetworkCmdPath)) } + if fs.Changed("network-backend") { + options = append(options, libpod.WithNetworkBackend(cfg.Network.NetworkBackend)) + } if fs.Changed("events-backend") { options = append(options, libpod.WithEventsLogger(cfg.Engine.EventsLogger)) |