summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Holzinger <pholzing@redhat.com>2021-11-10 21:16:30 +0100
committerPaul Holzinger <pholzing@redhat.com>2021-11-10 21:16:30 +0100
commit3690532b3be186c03071d9c845295e7158a0f7f5 (patch)
treeb3b81afc2bd161f9cb74ddaab5de571ea9b6e3bd
parent27de152b5a1f6226a02a23fae36ff2dde9e271db (diff)
downloadpodman-3690532b3be186c03071d9c845295e7158a0f7f5.tar.gz
podman-3690532b3be186c03071d9c845295e7158a0f7f5.tar.bz2
podman-3690532b3be186c03071d9c845295e7158a0f7f5.zip
network reload return error if we cannot reload ports
As rootless we have to reload the port mappings. If it fails we should return an error instead of the warning. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
-rw-r--r--libpod/networking_slirp4netns.go5
1 files changed, 1 insertions, 4 deletions
diff --git a/libpod/networking_slirp4netns.go b/libpod/networking_slirp4netns.go
index 8dbd12c6e..674075e23 100644
--- a/libpod/networking_slirp4netns.go
+++ b/libpod/networking_slirp4netns.go
@@ -686,10 +686,7 @@ func (c *Container) reloadRootlessRLKPortMapping() error {
conn, err := openUnixSocket(filepath.Join(c.runtime.config.Engine.TmpDir, "rp", c.config.ID))
if err != nil {
- // This is not a hard error for backwards compatibility. A container started
- // with an old version did not created the rootlessport socket.
- logrus.Warnf("Could not reload rootless port mappings, port forwarding may no longer work correctly: %v", err)
- return nil
+ return errors.Wrap(err, "could not reload rootless port mappings, port forwarding may no longer work correctly")
}
defer conn.Close()
enc := json.NewEncoder(conn)