1
0
Fork 0
mirror of https://github.com/containers/ansible-podman-collections.git synced 2026-02-04 07:11:49 +00:00

Don't include shared 'net' if network is host in pods (#348)

This commit is contained in:
Sergey 2021-11-29 00:04:53 +02:00 committed by GitHub
parent 05515e8307
commit d5e52d813f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -413,6 +413,9 @@ class PodmanPodDiff:
after = self.params['share'].split(",")
else:
after = ['uts', 'ipc', 'net']
if self.params['network'] == 'host':
after.remove('net')
before, after = sorted(list(set(before))), sorted(list(set(after)))
return self._diff_update_and_compare('share', before, after)