mirror of
https://github.com/roles-ansible/ansible_role_versioncheck.git
synced 2024-08-16 15:59:49 +02:00
Update versioncheck mechanism
This commit is contained in:
parent
ad13d8b532
commit
3a46a61f06
2 changed files with 5 additions and 4 deletions
|
@ -3,7 +3,7 @@ galaxy_info:
|
|||
author: L3D
|
||||
description: Make sure you are only executing ansible with at least a specific ansible version.
|
||||
license: "MIT"
|
||||
min_ansible_version: 2.9
|
||||
min_ansible_version: 2.7
|
||||
github_branch: master
|
||||
role_name: ansible_version
|
||||
platforms:
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
---
|
||||
- name: "check if ansible version is above {{ check_ansible_version }}"
|
||||
assert:
|
||||
that: "ansible_version.full is version_compare(check_ansible_version, '>=')"
|
||||
msg: >
|
||||
"You need at least ansible version {{ check_ansible_version }}. Current Version: {{ ansible_version.full }}"
|
||||
that:
|
||||
- "ansible_version.full is version_compare(check_ansible_version, '>=')"
|
||||
fail_msg: "[ERROR] You need at least ansible version {{ check_ansible_version }}. Current Version: {{ ansible_version.full }}"
|
||||
success_msg: "Congratulations. You are using ansible version {{ ansible_version.full }}"
|
||||
delegate_to: localhost
|
||||
|
|
Loading…
Reference in a new issue