From 38bd4010cfde804bb07a2eef32d28a332027a173 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Thu, 24 Mar 2022 13:57:33 +0100 Subject: network setup: fail if slirp4netns is not installed I do not see why we should only log an error. If slirp4netns is requested but not installed we should error. [NO NEW TESTS NEEDED] Signed-off-by: Paul Holzinger --- libpod/networking_slirp4netns.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'libpod') diff --git a/libpod/networking_slirp4netns.go b/libpod/networking_slirp4netns.go index b0247dc5c..3f6c4bef2 100644 --- a/libpod/networking_slirp4netns.go +++ b/libpod/networking_slirp4netns.go @@ -216,8 +216,7 @@ func (r *Runtime) setupSlirp4netns(ctr *Container, netns ns.NetNS) error { var err error path, err = exec.LookPath("slirp4netns") if err != nil { - logrus.Errorf("Could not find slirp4netns, the network namespace won't be configured: %v", err) - return nil + return fmt.Errorf("could not find slirp4netns, the network namespace can't be configured: %w", err) } } -- cgit v1.2.3-54-g00ecf