Cleanup CNI Networks on reboot

CNI sometimes leaves Network information in /var/lib/cni/networks
when the system crashes or containers do not shut down properly.

This PR will cleanup these left over files, so that container engines
will get a clean enviroment when the system reboots.

Related to: https://github.com/containers/podman/issues/3759

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
Daniel J Walsh
2020-12-11 09:16:38 -05:00
parent dd954781e6
commit 2e0a9c453b

View File

@ -1,4 +1,5 @@
# /tmp/podman-run-* directory can contain content for Podman containers that have run
# for many days. This following line prevents systemd from removing this content.
x /tmp/podman-run-.*
d /run/podman 0700 root root
x /tmp/podman-run-*
D! /run/podman 0700 root root
D! /var/lib/cni/networks