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

Fix play_kube not working when yaml not installed on target (#415) (#419)

Signed-off-by: tcmal <oscar.shrimpton.personal@gmail.com>
This commit is contained in:
Oscar 2022-05-01 09:48:43 +01:00 committed by GitHub
parent 98c516292f
commit 20a982b564
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -193,7 +193,7 @@ class PodmanKubeManagement:
"No metadata in Kube file!\n%s" % pod)
else:
with open(self.module.params['kube_file']) as text:
re_pod = NAME.search(text)
re_pod = NAME.search(text.read())
if re_pod:
pod_name = re_pod.group(1)
if not pod_name: