Skip to content

Commit 32250be

Browse files
committed
Improve Jinja2 spacing
1 parent a314a20 commit 32250be

18 files changed

Lines changed: 42 additions & 42 deletions

File tree

roles/fips/tasks/el7.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
- name: 'Generate boot=UUID=XXXX kernel command'
1515
ansible.builtin.set_fact:
1616
boot_cmd: "boot=UUID={{ boot_mount[0]['uuid'] }}"
17-
when: boot_mount|length > 0
17+
when: boot_mount | length > 0
1818

1919
- name: 'Edit kernel command-line to include the fips=1 and boot=UUID=XXXX argument'
2020
ansible.builtin.shell: 'grubby --update-kernel=DEFAULT --args="fips=1 {{ boot_cmd | default() }}"'

roles/foreman_installer/tasks/install.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323

2424
- name: 'Run installer'
2525
ansible.builtin.shell: >
26-
{{ foreman_installer_command }} {{ (foreman_installer_verbose|bool) | ternary("-v", "") }}
27-
{{ (foreman_installer_no_colors|bool) | ternary("--no-colors", "") }}
28-
{{ (foreman_installer_version is version('3.4', '<') and foreman_installer_disable_system_checks|bool) | ternary("--disable-system-checks", "") }}
29-
{{ (foreman_installer_version is version('3.4', '>=') and foreman_installer_disable_system_checks|bool and foreman_installer_scenario in ['katello']) | ternary("--tuning development", "") }}
26+
{{ foreman_installer_command }} {{ (foreman_installer_verbose | bool) | ternary("-v", "") }}
27+
{{ (foreman_installer_no_colors | bool) | ternary("--no-colors", "") }}
28+
{{ (foreman_installer_version is version('3.4', '<') and foreman_installer_disable_system_checks | bool) | ternary("--disable-system-checks", "") }}
29+
{{ (foreman_installer_version is version('3.4', '>=') and foreman_installer_disable_system_checks | bool and foreman_installer_scenario in ['katello']) | ternary("--tuning development", "") }}
3030
{{ foreman_installer_scenario_flag }} {{ foreman_installer_scenario }}
3131
{{ foreman_installer_options_joined }}
3232
when: not foreman_installer_skip_installer

roles/foreman_installer/tasks/upgrade.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
- name: 'Set internal installer options'
2121
ansible.builtin.set_fact:
22-
foreman_installer_options_internal_use_only: "{{ [ '--upgrade', '--certs-update-all' ] + foreman_installer_options_internal_use_only }}"
22+
foreman_installer_options_internal_use_only: "{{ ['--upgrade', '--certs-update-all'] + foreman_installer_options_internal_use_only }}"
2323
when:
2424
- foreman_installer_version is version('2.1', '<')
2525
- foreman_installer_scenario != 'foreman'

roles/foreman_provisioning/tasks/configure_centos_7.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
- name: 'Get CentOS 7 info'
1919
ansible.builtin.set_fact:
20-
foreman_provisioning_centos73: "{{ foreman_provisioning_centos73_json.stdout|from_json }}"
20+
foreman_provisioning_centos73: "{{ foreman_provisioning_centos73_json.stdout | from_json }}"
2121

2222
- name: 'Find kickstart templates'
2323
ansible.builtin.shell: >
@@ -27,7 +27,7 @@
2727

2828
- name: 'Set kickstart templates'
2929
ansible.builtin.set_fact:
30-
kickstart_templates: "{{ kickstart_templates_json.stdout|from_json }}"
30+
kickstart_templates: "{{ kickstart_templates_json.stdout | from_json }}"
3131

3232
- name: 'Associate kickstart templates to CentOS 7'
3333
ansible.builtin.shell: >

roles/foreman_provisioning/tasks/configure_debian_9_3.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
- name: 'Get CentOS 9.3 info'
1515
ansible.builtin.set_fact:
16-
foreman_provisioning_debian93: "{{ foreman_provisioning_debian93_json.stdout|from_json }}"
16+
foreman_provisioning_debian93: "{{ foreman_provisioning_debian93_json.stdout | from_json }}"
1717

1818
- name: 'Find preseed templates'
1919
ansible.builtin.shell: >
@@ -23,7 +23,7 @@
2323

2424
- name: 'Set preseed templates'
2525
ansible.builtin.set_fact:
26-
preseed_templates: "{{ preseed_templates_json.stdout|from_json }}"
26+
preseed_templates: "{{ preseed_templates_json.stdout | from_json }}"
2727

2828
- name: 'Associate preseed templates to Debian 9.3'
2929
ansible.builtin.shell: >

roles/foreman_provisioning/tasks/configure_fedora_27.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
- name: 'Get Fedora 27 info'
1515
ansible.builtin.set_fact:
16-
foreman_provisioning_fedora27: "{{ foreman_provisioning_fedora27_json.stdout|from_json }}"
16+
foreman_provisioning_fedora27: "{{ foreman_provisioning_fedora27_json.stdout | from_json }}"
1717

1818
- name: 'Find kickstart templates'
1919
ansible.builtin.shell: >
@@ -23,7 +23,7 @@
2323

2424
- name: 'Set kickstart templates'
2525
ansible.builtin.set_fact:
26-
kickstart_templates: "{{ kickstart_templates_json.stdout|from_json }}"
26+
kickstart_templates: "{{ kickstart_templates_json.stdout | from_json }}"
2727

2828
- name: 'Associate kickstart templates to Fedora 27'
2929
ansible.builtin.shell: >

roles/foreman_provisioning/tasks/configure_ubuntu_17_10.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
- name: 'Get Ubuntu 17.10 info'
1515
ansible.builtin.set_fact:
16-
foreman_provisioning_ubuntu1710: "{{ foreman_provisioning_ubuntu1710_json.stdout|from_json }}"
16+
foreman_provisioning_ubuntu1710: "{{ foreman_provisioning_ubuntu1710_json.stdout | from_json }}"
1717

1818
- name: 'Find preseed templates'
1919
ansible.builtin.shell: >
@@ -23,7 +23,7 @@
2323

2424
- name: 'Set preseed templates'
2525
ansible.builtin.set_fact:
26-
preseed_templates: "{{ preseed_templates_json.stdout|from_json }}"
26+
preseed_templates: "{{ preseed_templates_json.stdout | from_json }}"
2727

2828
- name: 'Associate preseed templates to Ubuntu 17.10'
2929
ansible.builtin.shell: >

roles/foreman_provisioning_infrastructure/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
- name: 'Set smart proxy id'
1414
ansible.builtin.set_fact:
15-
foreman_provisioning_smart_proxy: "{{ foreman_provisioning_smart_proxy_json.stdout|from_json }}"
15+
foreman_provisioning_smart_proxy: "{{ foreman_provisioning_smart_proxy_json.stdout | from_json }}"
1616

1717
- name: 'Refresh features'
1818
ansible.builtin.shell: >

roles/foreman_seeder/hostgroups/tasks/main.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
- name: 'Create operating systems'
44
ansible.builtin.shell: >
55
{% if 'minor' in item %}
6-
{% set title = item.name +' '+ item.major +'.'+ item.minor %}
6+
{% set title = item.name + ' ' + item.major + '.' + item.minor %}
77
{% else %}
8-
{% set title = item.name +' '+ item.major %}
8+
{% set title = item.name + ' ' + item.major %}
99
{% endif %}
1010
{{ foreman_seeder_hostgroups_hammer }} --output=silent os info --name "{{ title }}" ||
1111
{{ foreman_seeder_hostgroups_hammer }} --output=silent os info --title "{{ title }}" ||
@@ -53,7 +53,7 @@
5353

5454
- name: 'Set kickstart templates'
5555
ansible.builtin.set_fact:
56-
kickstart_templates: "{{ kickstart_templates_json.stdout|from_json }}"
56+
kickstart_templates: "{{ kickstart_templates_json.stdout | from_json }}"
5757
tags:
5858
- seed
5959

@@ -67,16 +67,16 @@
6767

6868
- name: 'Set preseed templates'
6969
ansible.builtin.set_fact:
70-
preseed_templates: "{{ preseed_templates_json.stdout|from_json }}"
70+
preseed_templates: "{{ preseed_templates_json.stdout | from_json }}"
7171
tags:
7272
- seed
7373

7474
- name: 'Associate kickstart templates to operating systems'
7575
ansible.builtin.shell: >
7676
{% if 'minor' in item[0] %}
77-
{% set title = item[0].name +' '+ item[0].major +'.'+ item[0].minor %}
77+
{% set title = item[0].name + ' ' + item[0].major + '.' + item[0].minor %}
7878
{% else %}
79-
{% set title = item[0].name +' '+ item[0].major %}
79+
{% set title = item[0].name + ' ' + item[0].major %}
8080
{% endif %}
8181
{% if item[0].family == 'Redhat' %}
8282
{{ foreman_seeder_hostgroups_hammer }} template add-operatingsystem --id {{ item[1].Id }} --operatingsystem '{{ title }}'
@@ -92,9 +92,9 @@
9292
- name: 'Associate preseed templates to operating systems'
9393
ansible.builtin.shell: >
9494
{% if 'minor' in item[0] %}
95-
{% set title = item[0].name +' '+ item[0].major +'.'+ item[0].minor %}
95+
{% set title = item[0].name + ' ' + item[0].major + '.' + item[0].minor %}
9696
{% else %}
97-
{% set title = item[0].name +' '+ item[0].major %}
97+
{% set title = item[0].name + ' ' + item[0].major %}
9898
{% endif %}
9999
{% if item[0].family == 'Debian' %}
100100
{{ foreman_seeder_hostgroups_hammer }} template add-operatingsystem --id {{ item[1].Id }} --operatingsystem '{{ title }}'
@@ -121,11 +121,11 @@
121121
- name: 'Create hostgroups'
122122
ansible.builtin.shell: >
123123
{% if 'minor' in item %}
124-
{% set os_title = item.name +' '+ item.major +'.'+ item.minor %}
124+
{% set os_title = item.name + ' ' + item.major + '.' + item.minor %}
125125
{% else %}
126-
{% set os_title = item.name +' '+ item.major %}
126+
{% set os_title = item.name + ' ' + item.major %}
127127
{% endif %}
128-
{% set name = 'Forklift '+ os_title %}
128+
{% set name = 'Forklift ' + os_title %}
129129
{{ foreman_seeder_hostgroups_hammer }} --output=silent hostgroup info --name "{{ name }}" ||
130130
{{ foreman_seeder_hostgroups_hammer }} hostgroup create
131131
--name '{{ name }}'

roles/foreman_server_repositories/tasks/main.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,19 @@
1010
ansible.builtin.include_role:
1111
role: theforeman.operations.puppet_repositories
1212
when:
13-
- foreman_server_repositories_puppet|bool
13+
- foreman_server_repositories_puppet | bool
1414

1515
- name: Load foreman_repositories
1616
ansible.builtin.include_role:
1717
role: foreman_repositories
18-
when: foreman_server_repositories_foreman|bool
18+
when: foreman_server_repositories_foreman | bool
1919

2020
- name: Load katello_repositories
2121
ansible.builtin.include_role:
2222
role: katello_repositories
23-
when: foreman_server_repositories_katello|bool
23+
when: foreman_server_repositories_katello | bool
2424

2525
- name: Load foreman_client_repositories
2626
ansible.builtin.include_role:
2727
role: foreman_client_repositories
28-
when: foreman_server_repositories_foreman_client|bool
28+
when: foreman_server_repositories_foreman_client | bool

0 commit comments

Comments
 (0)