summaryrefslogtreecommitdiffstats
path: root/roles/openshift_metrics/tasks/install_hosa.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'roles/openshift_metrics/tasks/install_hosa.yaml')
-rw-r--r--roles/openshift_metrics/tasks/install_hosa.yaml13
1 files changed, 10 insertions, 3 deletions
diff --git a/roles/openshift_metrics/tasks/install_hosa.yaml b/roles/openshift_metrics/tasks/install_hosa.yaml
index 7c9bc26d0..3624cb5ab 100644
--- a/roles/openshift_metrics/tasks/install_hosa.yaml
+++ b/roles/openshift_metrics/tasks/install_hosa.yaml
@@ -1,4 +1,11 @@
---
+- name: Ensure that Hawkular agent has nodes to run on
+ fail:
+ msg: |-
+ No schedulable nodes found matching node selector for Hawkular agent - '{{ openshift_metrics_hawkular_agent_nodeselector }}'
+ when:
+ - openshift_schedulable_node_labels | lib_utils_oo_has_no_matching_selector(openshift_metrics_hawkular_agent_nodeselector)
+
- name: Generate Hawkular Agent (HOSA) Cluster Role
template:
src: hawkular_openshift_agent_role.j2
@@ -38,7 +45,7 @@
kind: ClusterRole
name: hawkular-openshift-agent
subjects:
- - kind: ServiceAccount
- name: hawkular-openshift-agent
- namespace: "{{openshift_metrics_hawkular_agent_namespace}}"
+ - kind: ServiceAccount
+ name: hawkular-openshift-agent
+ namespace: "{{openshift_metrics_hawkular_agent_namespace}}"
changed_when: no