Skip to content

Commit 73b3ffe

Browse files
author
William Dyson
committed
added Tez gateway verify check
Signed-off-by: William Dyson <[email protected]>
1 parent e56122e commit 73b3ffe

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

roles/verify/parcels_and_roles/tasks/check_template_roles.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
| map('regex_replace','/.+','')
2323
| difference(role_mappings[template.service] | list)
2424
}}
25+
2526
- name: Ensure the host template service roles are valid
2627
assert:
2728
that: "{{ invalid_roles | length == 0 }}"
@@ -31,3 +32,12 @@
3132
fail_msg: >-
3233
Unknown role(s) {{ invalid_roles }} for service '{{ template.service }}'
3334
defined in host template '{{ host_template.name }}'.
35+
36+
- name: Ensure the Tez gateway has been deployed
37+
assert:
38+
that: "{{ 'GATEWAY' in (host_template.mappings['TEZ'] | default({})) }}"
39+
success_msg: The Tez gateway has been included as required
40+
fail_msg: The Tez gateway should be colocated with Hive On Tez roles
41+
when:
42+
- template.service == 'HIVE_ON_TEZ'
43+
- "'HIVESERVER2' in template.roles or 'GATEWAY' in template.roles"

0 commit comments

Comments
 (0)