feat(airgap): skip evaluations that aren't relevant to airgap

checking release version and tasks that depend on that check do not need to function since we won't
be aware of the version in an airgapped deployment
This commit is contained in:
Curtis John 2021-12-15 16:43:51 -05:00
parent 825ed3ad37
commit dd3c460bfa
No known key found for this signature in database
GPG key ID: 074FD4B4236B6865

View file

@ -6,6 +6,7 @@
- (k3s_release_version | replace('v', '')) is version_compare(k3s_min_version, '>=')
success_msg: "{{ k3s_release_version }} is supported by this role."
fail_msg: "{{ k3s_release_version }} is not supported by this role, please use xanmanning.k3s v1.x."
when: not k3s_airgap
- name: Check configuration in k3s_server and k3s_agent that needs alternate configuration
ansible.builtin.assert:
@ -34,6 +35,7 @@
{% endif %}
loop: "{{ k3s_deprecated_config }}"
when:
- not k3s_airgap
- (item.when is not defined
or (item.when is defined and (k3s_release_version | replace('v', '')) is version_compare(item.when, '>=')))
- not k3s_use_unsupported_config