diff options
author | Scott Dodson <sdodson@redhat.com> | 2017-02-06 15:43:43 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-06 15:43:43 -0500 |
commit | 1b910a05286d1368d69998a0f5c79fb6eaee2c21 (patch) | |
tree | 3489744a1a52ab12e03528e110701e173de0999b /roles/openshift_metrics/templates | |
parent | e27da6a8b7423f48d2bf989315cf41fc0188aee2 (diff) | |
parent | 21966b722781bb04b0b7a374685e428b77fd4f0a (diff) | |
download | openshift-1b910a05286d1368d69998a0f5c79fb6eaee2c21.tar.gz openshift-1b910a05286d1368d69998a0f5c79fb6eaee2c21.tar.bz2 openshift-1b910a05286d1368d69998a0f5c79fb6eaee2c21.tar.xz openshift-1b910a05286d1368d69998a0f5c79fb6eaee2c21.zip |
Merge pull request #3271 from jcantrill/metrics_node_selectors
fix 1406057. Allow openshift_metrics nodeselectors for components
Diffstat (limited to 'roles/openshift_metrics/templates')
-rw-r--r-- | roles/openshift_metrics/templates/hawkular_cassandra_rc.j2 | 6 | ||||
-rw-r--r-- | roles/openshift_metrics/templates/hawkular_metrics_rc.j2 | 6 | ||||
-rw-r--r-- | roles/openshift_metrics/templates/heapster.j2 | 6 |
3 files changed, 18 insertions, 0 deletions
diff --git a/roles/openshift_metrics/templates/hawkular_cassandra_rc.j2 b/roles/openshift_metrics/templates/hawkular_cassandra_rc.j2 index abd4ff939..876cb1915 100644 --- a/roles/openshift_metrics/templates/hawkular_cassandra_rc.j2 +++ b/roles/openshift_metrics/templates/hawkular_cassandra_rc.j2 @@ -19,6 +19,12 @@ spec: type: hawkular-cassandra spec: serviceAccount: cassandra +{% if node_selector is iterable and node_selector | length > 0 %} + nodeSelector: +{% for key, value in node_selector.iteritems() %} + {{key}}: "{{value}}" +{% endfor %} +{% endif %} containers: - image: "{{ openshift_metrics_image_prefix }}metrics-cassandra:{{ openshift_metrics_image_version }}" name: hawkular-cassandra-{{ node }} diff --git a/roles/openshift_metrics/templates/hawkular_metrics_rc.j2 b/roles/openshift_metrics/templates/hawkular_metrics_rc.j2 index f78621674..d39f1b43a 100644 --- a/roles/openshift_metrics/templates/hawkular_metrics_rc.j2 +++ b/roles/openshift_metrics/templates/hawkular_metrics_rc.j2 @@ -17,6 +17,12 @@ spec: name: hawkular-metrics spec: serviceAccount: hawkular +{% if node_selector is iterable and node_selector | length > 0 %} + nodeSelector: +{% for key, value in node_selector.iteritems() %} + {{key}}: "{{value}}" +{% endfor %} +{% endif %} containers: - image: {{openshift_metrics_image_prefix}}metrics-hawkular-metrics:{{openshift_metrics_image_version}} name: hawkular-metrics diff --git a/roles/openshift_metrics/templates/heapster.j2 b/roles/openshift_metrics/templates/heapster.j2 index eeca03be0..7c837db4d 100644 --- a/roles/openshift_metrics/templates/heapster.j2 +++ b/roles/openshift_metrics/templates/heapster.j2 @@ -18,6 +18,12 @@ spec: name: heapster spec: serviceAccountName: heapster +{% if node_selector is iterable and node_selector | length > 0 %} + nodeSelector: +{% for key, value in node_selector.iteritems() %} + {{key}}: "{{value}}" +{% endfor %} +{% endif %} containers: - name: heapster image: {{openshift_metrics_image_prefix}}metrics-heapster:{{openshift_metrics_image_version}} |