summaryrefslogtreecommitdiff
path: root/libpod/container_internal_linux.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-12-08 06:15:40 -0500
committerGitHub <noreply@github.com>2020-12-08 06:15:40 -0500
commit9b3a81a002e570b8a49e60c3dd3feb65d742f286 (patch)
tree78f983912e8efe3aa055b3d5db6abec0939f4fa3 /libpod/container_internal_linux.go
parente2f91207fc3e515c0a9f828433aaf80727f4b7c5 (diff)
parentb0286d6b43ebec367c0d9ed87bc6566d76ece8f8 (diff)
downloadpodman-9b3a81a002e570b8a49e60c3dd3feb65d742f286.tar.gz
podman-9b3a81a002e570b8a49e60c3dd3feb65d742f286.tar.bz2
podman-9b3a81a002e570b8a49e60c3dd3feb65d742f286.zip
Merge pull request #8571 from Luap99/podman-network-reload
Implement pod-network-reload
Diffstat (limited to 'libpod/container_internal_linux.go')
-rw-r--r--libpod/container_internal_linux.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/libpod/container_internal_linux.go b/libpod/container_internal_linux.go
index 72eaeac8e..1bf044f9d 100644
--- a/libpod/container_internal_linux.go
+++ b/libpod/container_internal_linux.go
@@ -231,6 +231,19 @@ func (c *Container) cleanupNetwork() error {
return nil
}
+// reloadNetwork reloads the network for the given container, recreating
+// firewall rules.
+func (c *Container) reloadNetwork() error {
+ result, err := c.runtime.reloadContainerNetwork(c)
+ if err != nil {
+ return err
+ }
+
+ c.state.NetworkStatus = result
+
+ return c.save()
+}
+
func (c *Container) getUserOverrides() *lookup.Overrides {
var hasPasswdFile, hasGroupFile bool
overrides := lookup.Overrides{}