Added pre_task to verify minimum Ansible version (#454)

This commit is contained in:
Angel Garza 2024-02-24 20:20:57 -05:00 committed by GitHub
parent 029eba6102
commit 83a0be3afd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,4 +1,13 @@
---
- name: Pre tasks
hosts: all
pre_tasks:
- name: Verify Ansible is version 2.11 or above. (If this fails you may need to update Ansible)
assert:
that: "ansible_version.full is version_compare('2.11', '>=')"
msg: >
"Ansible is out of date. See here for more info: https://docs.technotim.live/posts/ansible-automation/"
- name: Prepare Proxmox cluster
hosts: proxmox
gather_facts: true