aboutsummaryrefslogtreecommitdiff
path: root/pkg/checkpoint
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-12-15 15:25:14 +0100
committerGitHub <noreply@github.com>2021-12-15 15:25:14 +0100
commit7dabcbd7bcf78f3b5d310ed547801106da382618 (patch)
tree7b92c3ca37025a833a0d9651afeb19ba7c903cc8 /pkg/checkpoint
parentb01a421f3413ba01b2c189b82c8153bdbd2a05fb (diff)
parentef325bc8c4824537e4bfb21aa7e6114a6e5a8c09 (diff)
downloadpodman-7dabcbd7bcf78f3b5d310ed547801106da382618.tar.gz
podman-7dabcbd7bcf78f3b5d310ed547801106da382618.tar.bz2
podman-7dabcbd7bcf78f3b5d310ed547801106da382618.zip
Merge pull request #12534 from Luap99/network-db
network db rewrite
Diffstat (limited to 'pkg/checkpoint')
-rw-r--r--pkg/checkpoint/checkpoint_restore.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/pkg/checkpoint/checkpoint_restore.go b/pkg/checkpoint/checkpoint_restore.go
index c371adf5b..34bd8a124 100644
--- a/pkg/checkpoint/checkpoint_restore.go
+++ b/pkg/checkpoint/checkpoint_restore.go
@@ -78,6 +78,18 @@ func CRImportCheckpoint(ctx context.Context, runtime *libpod.Runtime, restoreOpt
}
}
+ if restoreOptions.IgnoreStaticIP || restoreOptions.IgnoreStaticMAC {
+ for net, opts := range ctrConfig.Networks {
+ if restoreOptions.IgnoreStaticIP {
+ opts.StaticIPs = nil
+ }
+ if restoreOptions.IgnoreStaticMAC {
+ opts.StaticMAC = nil
+ }
+ ctrConfig.Networks[net] = opts
+ }
+ }
+
ctrID := ctrConfig.ID
newName := false