Fix distribution/OS variables
This commit is contained in:
parent
f12ec3e9e0
commit
431bf0c9b7
|
@ -2,7 +2,7 @@
|
||||||
- name: Set some variables
|
- name: Set some variables
|
||||||
set_fact:
|
set_fact:
|
||||||
ssh_hardening_backup_suffix: "42.{{ ansible_date_time.date }}@{{ ansible_date_time.time }}~"
|
ssh_hardening_backup_suffix: "42.{{ ansible_date_time.date }}@{{ ansible_date_time.time }}~"
|
||||||
ssh_hardening_distri: "{{ (ansible_distribution|lower).split(' ')[0] }}"
|
ssh_hardening_distri: "{{ (ansible_distribution|lower).split(' ')[0] }}-{{ ansible_distribution_major_version }}"
|
||||||
|
|
||||||
|
|
||||||
- name: Get SSH version number
|
- name: Get SSH version number
|
||||||
|
@ -25,8 +25,8 @@
|
||||||
include_vars: "{{ item }}"
|
include_vars: "{{ item }}"
|
||||||
with_first_found:
|
with_first_found:
|
||||||
- "os_{{ ssh_hardening_distri }}.yml"
|
- "os_{{ ssh_hardening_distri }}.yml"
|
||||||
- "os_{{ ansible_distribution_family }}.yml"
|
- "os_{{ (ansible_distribution|lower).split(' ')[0] }}.yml"
|
||||||
- "os_{{ ansible_os_family }}.yml"
|
- "os_{{ (ansible_os_family|lower).split(' ')[0] }}.yml"
|
||||||
- "os_default.yml"
|
- "os_default.yml"
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue