mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Update validate_vars.yml
This commit is contained in:
parent
149c8f01ab
commit
69dc471547
1 changed files with 3 additions and 3 deletions
|
@ -37,11 +37,11 @@
|
|||
# I want to perform input validation for Ansible playbooks"
|
||||
# https://stackoverflow.com/questions/46664127/how-do-i-fail-a-task-in-ansible-if-the-variable-contains-a-boolean-value-i-want/46667499#46667499
|
||||
|
||||
# 2020-01-23: checks 53 + 53 + 53 vars...for now...expect this to change!
|
||||
# 2020-01-23: checks 53 + 53 + up-to-53 vars...for now...expect this to change!
|
||||
# Should we remove {xo_services, activity_server, ejabberd_xs, idmgr} as these
|
||||
# are officially now UNMAINTAINED in default_vars.yml and
|
||||
# https://github.com/iiab/iiab/blob/master/unmaintained-roles.txt etc?
|
||||
- name: Set vars_checklist for 53 + 53 + 53 vars ("XYZ_install" + "XYZ_enabled" + "XYZ_installed") to be checked
|
||||
- name: Set vars_checklist for 53 + 53 + up-to-53 vars ("XYZ_install" + "XYZ_enabled" + "XYZ_installed") to be checked
|
||||
set_fact:
|
||||
vars_checklist:
|
||||
- hostapd
|
||||
|
@ -139,7 +139,7 @@
|
|||
loop: "{{ vars_checklist }}"
|
||||
#register: var_pairs_validation
|
||||
|
||||
- name: 'DISALLOW "XYZ_install: False" WHEN "XYZ_installed is defined" IN /etc/iiab/iiab_state.yml ...for all {{ vars_checklist | length }} var pairs'
|
||||
- name: 'DISALLOW "XYZ_install: False" WHEN "XYZ_installed is defined" IN /etc/iiab/iiab_state.yml ...for up-to-{{ vars_checklist | length }} var pairs'
|
||||
assert:
|
||||
that: "{{ item }}_install or {{ item }}_installed is undefined"
|
||||
fail_msg: "{{ item }} ALREADY INSTALLED. IIAB DOES NOT SUPPORT UNINSTALLS. PLEASE SET '{{ item }}_install: True' e.g. IN: /etc/iiab/local_vars.yml"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue