summaryrefslogtreecommitdiff
path: root/libpod
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-05-11 18:30:52 -0400
committerGitHub <noreply@github.com>2021-05-11 18:30:52 -0400
commit59dd35750931547c66e34e999ab960c90f18f510 (patch)
treef135ce04d90289283e170aa140b4cce48ed0ac05 /libpod
parent8dcd5b893feb8b3b34386e6688d20b7ef098228b (diff)
parent30544f225e73a4180f4afb0d062006c9fa61a309 (diff)
downloadpodman-59dd35750931547c66e34e999ab960c90f18f510.tar.gz
podman-59dd35750931547c66e34e999ab960c90f18f510.tar.bz2
podman-59dd35750931547c66e34e999ab960c90f18f510.zip
Merge pull request #10310 from Luap99/restart-slirp
fix restart always with slirp4netns
Diffstat (limited to 'libpod')
-rw-r--r--libpod/container_internal.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/libpod/container_internal.go b/libpod/container_internal.go
index 051fe4b9e..53b85a466 100644
--- a/libpod/container_internal.go
+++ b/libpod/container_internal.go
@@ -283,6 +283,14 @@ func (c *Container) handleRestartPolicy(ctx context.Context) (_ bool, retErr err
return false, err
}
+ // setup slirp4netns again because slirp4netns will die when conmon exits
+ if c.config.NetMode.IsSlirp4netns() {
+ err := c.runtime.setupSlirp4netns(c)
+ if err != nil {
+ return false, err
+ }
+ }
+
if c.state.State == define.ContainerStateStopped {
// Reinitialize the container if we need to
if err := c.reinit(ctx, true); err != nil {