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

pod: Support passing multiple networks with params (#553)

Similar to #472, but for pods. there is also support there

Signed-off-by: Benjamin Schubert <contact@benschubert.me>
This commit is contained in:
Benjamin Schubert 2023-02-24 10:15:43 +00:00 committed by GitHub
parent 1bfa6396a5
commit 7c06ddec3b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -213,6 +213,10 @@ class PodmanPodModuleParams:
return c + ['--name', self.params['name']]
def addparam_network(self, c):
if LooseVersion(self.podman_version) >= LooseVersion('4.0.0'):
for net in self.params['network']:
c += ['--network', net]
return c
return c + ['--network', ",".join(self.params['network'])]
def addparam_network_aliases(self, c):