32 lines
2.1 KiB
YAML
32 lines
2.1 KiB
YAML
---
|
|
# tasks file for ./playbooks/roles/proxmox-patching
|
|
- name: Import variables specific to distribution
|
|
include_vars: "{{ item }}"
|
|
with_first_found:
|
|
- "{{ role_path }}/vars/{{ ansible_facts['distribution'] }}-{{ ansible_facts['distribution_version'] }}.yml"
|
|
- "{{ role_path }}/vars/{{ ansible_facts['distribution'] }}-{{ ansible_facts['distribution_major_version'] }}.yml"
|
|
- "{{ role_path }}/vars/{{ ansible_facts['distribution'] }}.yml"
|
|
# ansible_os_family is used as a fallback for distros which are not currently
|
|
# supported, but are based on a supported distro family. For example,
|
|
# Oracle, Rocky, Alma and Alibaba linux, which are all "RedHat" based.
|
|
- "{{ role_path }}/vars/{{ ansible_facts['os_family'] }}-{{ ansible_facts['distribution_version'] }}.yml"
|
|
- "{{ role_path }}/vars/{{ ansible_facts['os_family'] }}-{{ ansible_facts['distribution_major_version'] }}.yml"
|
|
- "{{ role_path }}/vars/{{ ansible_facts['os_family'] }}.yml"
|
|
# If neither distro nor family is supported, try a default configuration.
|
|
- "{{ role_path }}/vars/default.yml"
|
|
|
|
- name: Update everything for distribution
|
|
include_tasks: "{{ item }}"
|
|
with_first_found:
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['distribution'] }}-{{ ansible_facts['distribution_version'] }}.yml"
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['distribution'] }}-{{ ansible_facts['distribution_major_version'] }}.yml"
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['distribution'] }}.yml"
|
|
# ansible_os_family is used as a fallback for distros which are not currently
|
|
# supported, but are based on a supported distro family. For example,
|
|
# Oracle, Rocky, Alma and Alibaba linux, which are all "RedHat" based.
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['os_family'] }}-{{ ansible_facts['distribution_version'] }}.yml"
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['os_family'] }}-{{ ansible_facts['distribution_major_version'] }}.yml"
|
|
- "{{ role_path }}/tasks/dist/{{ ansible_facts['os_family'] }}.yml"
|
|
# If neither distro nor family is supported, try a default configuration.
|
|
- "{{ role_path }}/tasks/dist/no_dist_found.yml"
|