mirror of
https://github.com/ansible-collections/kubernetes.core.git
synced 2026-05-07 05:22:39 +00:00
I would liked to have an example like this when I was using the
documentation.
(cherry picked from commit 4d7dc2a7d1)
Co-authored-by: Birger Johan Nordølum <33870508+MindTooth@users.noreply.github.com>
This commit is contained in:
@@ -701,6 +701,21 @@ Examples
|
|||||||
wait_sleep: 10
|
wait_sleep: 10
|
||||||
wait_timeout: 360
|
wait_timeout: 360
|
||||||
|
|
||||||
|
- name: Wait for OpenShift bootstrap to complete
|
||||||
|
kubernetes.core.k8s_info:
|
||||||
|
api_version: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
name: bootstrap
|
||||||
|
namespace: kube-system
|
||||||
|
register: ocp_bootstrap_status
|
||||||
|
until: >
|
||||||
|
ocp_bootstrap_status.resources is defined and
|
||||||
|
(ocp_bootstrap_status.resources | length > 0) and
|
||||||
|
(ocp_bootstrap_status.resources[0].data.status is defined) and
|
||||||
|
(ocp_bootstrap_status.resources[0].data.status == 'complete')
|
||||||
|
retries: 60
|
||||||
|
delay: 15
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Return Values
|
Return Values
|
||||||
|
|||||||
@@ -120,6 +120,21 @@ EXAMPLES = r"""
|
|||||||
namespace: default
|
namespace: default
|
||||||
wait_sleep: 10
|
wait_sleep: 10
|
||||||
wait_timeout: 360
|
wait_timeout: 360
|
||||||
|
|
||||||
|
- name: Wait for OpenShift bootstrap to complete
|
||||||
|
kubernetes.core.k8s_info:
|
||||||
|
api_version: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
name: bootstrap
|
||||||
|
namespace: kube-system
|
||||||
|
register: ocp_bootstrap_status
|
||||||
|
until: >
|
||||||
|
ocp_bootstrap_status.resources is defined and
|
||||||
|
(ocp_bootstrap_status.resources | length > 0) and
|
||||||
|
(ocp_bootstrap_status.resources[0].data.status is defined) and
|
||||||
|
(ocp_bootstrap_status.resources[0].data.status == 'complete')
|
||||||
|
retries: 60
|
||||||
|
delay: 15
|
||||||
"""
|
"""
|
||||||
|
|
||||||
RETURN = r"""
|
RETURN = r"""
|
||||||
|
|||||||
Reference in New Issue
Block a user