32 lines
793 B
YAML
32 lines
793 B
YAML
---
|
|
|
|
# support debian 12
|
|
- name: "check for os support"
|
|
ansible.builtin.set_fact:
|
|
os_support: true
|
|
when:
|
|
- 'ansible_distribution == "Debian"'
|
|
- 'ansible_distribution_major_version == "12"'
|
|
|
|
# support ubuntu 22
|
|
- name: "check for os support"
|
|
ansible.builtin.set_fact:
|
|
os_support: true
|
|
when:
|
|
- 'ansible_distribution == "Ubuntu"'
|
|
- 'ansible_distribution_major_version == "22"'
|
|
|
|
# support ubuntu 24
|
|
- name: "check for os support"
|
|
ansible.builtin.set_fact:
|
|
os_support: true
|
|
when:
|
|
- 'ansible_distribution == "Ubuntu"'
|
|
- 'ansible_distribution_major_version == "24"'
|
|
|
|
# fail role when not supported
|
|
- name: "unsupported role"
|
|
ansible.builtin.fail:
|
|
msg: "This role not supported on this Operating System."
|
|
when:
|
|
- "os_support is not defined"
|