mirror of
https://github.com/ansible-collections/kubernetes.core.git
synced 2026-05-07 21:42:38 +00:00
Honor wait_timeout in k8s_info for missing resource (#360)
* Honor wait in k8s_info for missing resource The wait logic in the k8s_info module immediately returns when no resources are found, regardless whether a wait_timeout has been specified. This expands the logic to wait when a name has been provided. The case this is specifically meant to address is when querying for a resource that is indirectly created by another resource, for example, a pod created by a deployment or an operator. The existing logic in every other case should remain as it was before. This means if a query might return more than one resource--all pods with some label, for example--the module will return immediately if no pods are found, even if a wait_timeout has been provided. * Add changelog fragment
This commit is contained in:
2
changelogs/fragments/360-k8s_info-wait-timeout.yaml
Normal file
2
changelogs/fragments/360-k8s_info-wait-timeout.yaml
Normal file
@@ -0,0 +1,2 @@
|
||||
bugfixes:
|
||||
- respect the ``wait_timeout`` parameter in the ``k8s`` and ``k8s_info`` modules when a resource does not exist (https://github.com/ansible-collections/community.kubernetes/issues/344).
|
||||
Reference in New Issue
Block a user