|
16 | 16 | loop: "{{ __var_files }}" |
17 | 17 | vars: |
18 | 18 | __vars_file: "{{ role_path }}/vars/{{ item }}" |
19 | | - __distribution_major: "{{ ansible_distribution ~ '_' ~ ansible_distribution_major_version }}" |
20 | | - __distribution_minor: "{{ ansible_distribution ~ '_' ~ ansible_distribution_version }}" |
| 19 | + __distribution_major: "{{ ansible_facts['distribution'] ~ '_' ~ ansible_facts['distribution_major_version'] }}" |
| 20 | + __distribution_minor: "{{ ansible_facts['distribution'] ~ '_' ~ ansible_facts['distribution_version'] }}" |
21 | 21 | # Enables loading of shared vars between SLES and SLES_SAP |
22 | | - __distribution_major_split: "{{ ansible_distribution.split('_')[0] ~ '_' ~ ansible_distribution_major_version }}" |
23 | | - __distribution_minor_split: "{{ ansible_distribution.split('_')[0] ~ '_' ~ ansible_distribution_version }}" |
| 22 | + __distribution_major_split: "{{ ansible_facts['distribution'].split('_')[0] ~ '_' ~ ansible_facts['distribution_major_version'] }}" |
| 23 | + __distribution_minor_split: "{{ ansible_facts['distribution'].split('_')[0] ~ '_' ~ ansible_facts['distribution_version'] }}" |
24 | 24 | __var_files: >- |
25 | 25 | {{ |
26 | 26 | [ |
27 | | - ansible_os_family ~ '.yml', |
28 | | - (ansible_distribution ~ '.yml') if ansible_distribution != ansible_os_family else None, |
| 27 | + ansible_facts['os_family'] ~ '.yml', |
| 28 | + (ansible_facts['distribution'] ~ '.yml') if ansible_facts['distribution'] != ansible_facts['os_family'] else None, |
29 | 29 | (__distribution_major_split ~ '.yml') if __distribution_major_split != __distribution_major else None, |
30 | 30 | (__distribution_minor_split ~ '.yml') if __distribution_minor_split != __distribution_minor else None, |
31 | 31 | __distribution_major ~ '.yml', |
|
52 | 52 | ansible.builtin.include_tasks: '{{ item }}/{{ __sap_netweaver_preconfigure_fact_assert_filename_prefix }}installation.yml' |
53 | 53 | when: sap_netweaver_preconfigure_config_all|d(true) or sap_netweaver_preconfigure_installation|d(false) |
54 | 54 | with_first_found: |
55 | | - - '{{ ansible_distribution.split("_")[0] }}' |
56 | | - - '{{ ansible_distribution }}' |
| 55 | + - "{{ ansible_facts['distribution'].split('_')[0] }}" |
| 56 | + - "{{ ansible_facts['distribution'] }}" |
57 | 57 |
|
58 | 58 | - name: Include tasks from 'configuration.yml' |
59 | 59 | ansible.builtin.include_tasks: '{{ item }}/{{ __sap_netweaver_preconfigure_fact_assert_filename_prefix }}configuration.yml' |
60 | 60 | when: sap_netweaver_preconfigure_config_all|d(true) or sap_netweaver_preconfigure_configuration|d(false) |
61 | 61 | with_first_found: |
62 | | - - '{{ ansible_distribution.split("_")[0] }}' |
63 | | - - '{{ ansible_distribution }}' |
| 62 | + - "{{ ansible_facts['distribution'].split('_')[0] }}" |
| 63 | + - "{{ ansible_facts['distribution'] }}" |
0 commit comments