Browse Source

Merge pull request #9700 from Miciah/get-cluster-resource-for-SDN-check-in-health.yml

Get cluster resources for SDN check in health.yml
OpenShift Merge Robot 6 years ago
parent
commit
10f5d3a015
1 changed files with 18 additions and 0 deletions
  1. 18 0
      playbooks/openshift-checks/private/health.yml

+ 18 - 0
playbooks/openshift-checks/private/health.yml

@@ -3,10 +3,28 @@
   hosts: oo_all_hosts
 
   roles:
+  - lib_openshift
   - openshift_health_checker
   vars:
   - r_openshift_health_checker_playbook_context: health
   post_tasks:
+  - name: Get cluster resources
+    delegate_to: "{{ groups.oo_first_master.0 }}"
+    run_once: True
+    oc_obj:
+      state: list
+      kind: "{{ item }}"
+      all_namespaces: True
+    register: resources
+    with_items:
+    - nodes
+    - pods
+    - services
+    - endpoints
+    - routes
+    - clusternetworks
+    - hostsubnets
+    - netnamespaces
   - name: Run health checks (@health)
     action: openshift_health_check
     args: