Skip to content

Commit 7136dac

Browse files
committed
playbooks: ansible-lint fix no-free-form
Fix no-free-form ansible-lint rule violations Fixed no-free-form rule violations across 18 file(s). Affected files include: - playbooks/roles/blktests/handlers/main.yml - playbooks/roles/blktests/tasks/main.yml - playbooks/roles/cxl/tasks/cxl-dcd-setup/main.yml - playbooks/roles/cxl/tasks/main.yml - playbooks/roles/devconfig/tasks/main.yml ... and 13 more files Applied using the ansible-lint-fix-rules.py script with --fix=no-free-form. Generated-by: Ansible Lint (ansible-lint-fix-rules.py) Signed-off-by: Daniel Gomez <[email protected]>
1 parent 19fa0a4 commit 7136dac

File tree

18 files changed

+134
-52
lines changed

18 files changed

+134
-52
lines changed
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
---
22
# SPDX-License-Identifier GPL-2.0+ OR MIT
33
- name: Restart watchdog daemon
4-
ansible.builtin.service: name="{{watchdog_service_name}}" state=restarted
4+
ansible.builtin.service:
5+
name: "{{watchdog_service_name}}"
6+
state: restarted

playbooks/roles/blktests/tasks/main.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,8 @@
170170

171171
- name: Print uname for each host
172172
tags: ["blktests", "run_tests"]
173-
ansible.builtin.debug: var=ansible_kernel
173+
ansible.builtin.debug:
174+
var: ansible_kernel
174175
- name: Get used target kernel version
175176
tags: ["blktests", "copy_results", "augment_expunge_list"]
176177
ansible.builtin.command: "uname -r"
@@ -255,7 +256,9 @@
255256
- blktests_test_devs|length != 0
256257

257258
- name: Hint to watchdog tests are about to kick off
258-
ansible.builtin.file: path="{{ blktests_workflow_target }}/.begin" state=touch
259+
ansible.builtin.file:
260+
path: "{{ blktests_workflow_target }}/.begin"
261+
state: touch
259262
delegate_to: localhost
260263
tags: ["blktests", "run_tests"]
261264
when:
@@ -369,15 +372,19 @@
369372
- kdevops_run_blktests|bool
370373

371374
- name: Remove watchdog hint that tests have started
372-
ansible.builtin.file: path="{{ blktests_workflow_target }}/.begin" state=absent
375+
ansible.builtin.file:
376+
path: "{{ blktests_workflow_target }}/.begin"
377+
state: absent
373378
delegate_to: localhost
374379
tags: ["blktests", "run_tests"]
375380
when:
376381
- kdevops_run_blktests|bool
377382
run_once: true
378383

379384
- name: Clean up our localhost results/last-run directory
380-
ansible.builtin.file: path="{{ blktests_results_target }}/{{ item }}" state=absent
385+
ansible.builtin.file:
386+
path: "{{ blktests_results_target }}/{{ item }}"
387+
state: absent
381388
delegate_to: localhost
382389
with_items:
383390
- "last-run"

playbooks/roles/cxl/tasks/cxl-dcd-setup/main.yml

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
tags: ["cxl-dcd-setup"]
88
delegate_to: localhost
99

10-
- ansible.builtin.debug: var=command_output.stdout_lines
10+
- ansible.builtin.debug:
11+
var: command_output.stdout_lines
1112
tags: ["cxl-dcd-setup"]
1213

1314
- name: Show DC extents added
@@ -16,7 +17,8 @@
1617
register: command_output
1718
tags: ["cxl-dcd-setup"]
1819

19-
- ansible.builtin.debug: var=command_output.stdout_lines
20+
- ansible.builtin.debug:
21+
var: command_output.stdout_lines
2022
tags: ["cxl-dcd-setup"]
2123

2224
- name: Create dax devices for DC region
@@ -26,7 +28,8 @@
2628
register: command_output
2729
tags: ["cxl-dcd-setup"]
2830

29-
- ansible.builtin.debug: var=command_output.stdout_lines
31+
- ansible.builtin.debug:
32+
var: command_output.stdout_lines
3033
tags: ["cxl-dcd-setup"]
3134

3235
- name: Show dax devices added
@@ -35,7 +38,8 @@
3538
register: command_output
3639
tags: ["cxl-dcd-setup"]
3740

38-
- ansible.builtin.debug: var=command_output.stdout_lines
41+
- ansible.builtin.debug:
42+
var: command_output.stdout_lines
3943
tags: ["cxl-dcd-setup"]
4044

4145
- name: Convert dax devices to system RAM and online
@@ -45,7 +49,8 @@
4549
register: command_output
4650
tags: ["cxl-dcd-setup"]
4751

48-
- ansible.builtin.debug: var=command_output.stdout_lines
52+
- ansible.builtin.debug:
53+
var: command_output.stdout_lines
4954
tags: ["cxl-dcd-setup"]
5055

5156
- name: Show system memory with lsmem
@@ -54,5 +59,6 @@
5459
register: command_output
5560
tags: ["cxl-dcd-setup"]
5661

57-
- ansible.builtin.debug: var=command_output.stdout_lines
62+
- ansible.builtin.debug:
63+
var: command_output.stdout_lines
5864
tags: ["cxl-dcd-setup"]

playbooks/roles/cxl/tasks/main.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,8 @@
9797

9898
- name: Print uname for each host
9999
tags: ["ndctl", "cxl-test-prep", "copy_results"]
100-
ansible.builtin.debug: var=ansible_kernel
100+
ansible.builtin.debug:
101+
var: ansible_kernel
101102
- name: Clear out old meson results directory on target hosts
102103
become: true
103104
become_flags: "su - -c"
@@ -161,7 +162,9 @@
161162
- kdevops_run_cxl_tests|bool
162163

163164
- name: Clean up our localhost results/last-run directory
164-
ansible.builtin.file: path="{{ cxl_results_target }}/{{ item }}" state=absent
165+
ansible.builtin.file:
166+
path: "{{ cxl_results_target }}/{{ item }}"
167+
state: absent
165168
delegate_to: localhost
166169
with_items:
167170
- "last-run"
@@ -171,7 +174,9 @@
171174
tags: ["ndctl", "cxl-test-meson", "copy_results"]
172175

173176
- name: Create empty last-run directory
174-
ansible.builtin.file: path="{{ cxl_results_target }}/" state=directory
177+
ansible.builtin.file:
178+
path: "{{ cxl_results_target }}/"
179+
state: directory
175180
delegate_to: localhost
176181
run_once: true
177182
tags: ["ndctl", "cxl-test-meson", "copy_results"]

playbooks/roles/devconfig/tasks/main.yml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,8 @@
143143
when: dev_git_config_file.stat.exists
144144

145145
- name: Check if the system has a user vimrc file
146-
ansible.builtin.stat: path=~/.vimrc
146+
ansible.builtin.stat:
147+
path: ~/.vimrc
147148
register: dev_vimrc_file
148149
tags: vimrc
149150

@@ -158,7 +159,8 @@
158159
become: true
159160
become_flags: "su - -c"
160161
become_method: sudo
161-
ansible.builtin.stat: path=~/.vimrc
162+
ansible.builtin.stat:
163+
path: ~/.vimrc
162164
register: dev_root_vimrc_file
163165
tags: vimrc
164166

@@ -226,15 +228,17 @@
226228
when: dev_bash_config_file_copied_root is success
227229

228230
- name: Check to see if system has GRUB2
229-
ansible.builtin.stat: path=/etc/default/grub
231+
ansible.builtin.stat:
232+
path: /etc/default/grub
230233
register: grub2_config_file
231234
tags: ["console"]
232235

233236
- name: Check to see if stupid /etc/default/grub.d/15_timeout.cfg exists
234237
become: true
235238
become_flags: "su - -c"
236239
become_method: sudo
237-
ansible.builtin.stat: path=/etc/default/grub.d/15_timeout.cfg
240+
ansible.builtin.stat:
241+
path: /etc/default/grub.d/15_timeout.cfg
238242
register: stupid_cloud_grub_timeout
239243
when:
240244
- devconfig_enable_console|bool
@@ -641,7 +645,8 @@
641645
when: devconfig_enable_systemd_journal_remote|bool
642646

643647
- name: Enables systemd's watchdog
644-
ansible.builtin.stat: path=/etc/systemd/system.conf
648+
ansible.builtin.stat:
649+
path: /etc/systemd/system.conf
645650
register: systemd_config_file
646651
tags: ["systemd_watchdog"]
647652

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
---
22
# SPDX-License-Identifier GPL-2.0+ OR MIT
33
- name: Restart watchdog daemon
4-
ansible.builtin.service: name="{{watchdog_service_name}}" state=restarted
4+
ansible.builtin.service:
5+
name: "{{watchdog_service_name}}"
6+
state: restarted

playbooks/roles/fstests/tasks/main.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1080,15 +1080,20 @@
10801080

10811081
- name: Print uname for each host
10821082
tags: ["oscheck", "fstests", "run_tests"]
1083-
ansible.builtin.debug: var=ansible_kernel
1083+
ansible.builtin.debug:
1084+
var: ansible_kernel
10841085
- name: Clean up our localhost results/last-run directory
1085-
ansible.builtin.file: path="{{ fstests_results_target }}/" state=absent
1086+
ansible.builtin.file:
1087+
path: "{{ fstests_results_target }}/"
1088+
state: absent
10861089
delegate_to: localhost
10871090
run_once: true
10881091
tags: ["oscheck", "fstests", "copy_results", "clean_local_results"]
10891092

10901093
- name: Create empty last-run directory
1091-
ansible.builtin.file: path="{{ fstests_results_target }}/" state=directory
1094+
ansible.builtin.file:
1095+
path: "{{ fstests_results_target }}/"
1096+
state: directory
10921097
delegate_to: localhost
10931098
run_once: true
10941099
tags: ["oscheck", "fstests", "copy_results", "clean_local_results"]
@@ -1134,7 +1139,9 @@
11341139
- devconfig_enable_systemd_journal_remote|bool
11351140

11361141
- name: Hint to watchdog tests are about to kick off
1137-
ansible.builtin.file: path="{{ fstests_workflow_dir }}/.begin" state=touch
1142+
ansible.builtin.file:
1143+
path: "{{ fstests_workflow_dir }}/.begin"
1144+
state: touch
11381145
delegate_to: localhost
11391146
tags: ["oscheck", "fstests", "run_tests"]
11401147
when:
@@ -1296,7 +1303,9 @@
12961303
tags: ["oscheck", "fstests", "run_tests", "monitoring", "monitor_collect"]
12971304

12981305
- name: Remove watchdog hint that tests have started
1299-
ansible.builtin.file: path="{{ fstests_workflow_dir }}/.begin" state=absent
1306+
ansible.builtin.file:
1307+
path: "{{ fstests_workflow_dir }}/.begin"
1308+
state: absent
13001309
delegate_to: localhost
13011310
tags: ["oscheck", "fstests", "run_tests"]
13021311
when:
@@ -1604,7 +1613,8 @@
16041613
run_once: true
16051614

16061615
- name: Get stat of new files not yet committed, ie, new expunge files
1607-
ansible.builtin.stat: path="{{ fstests_results_target }}/new_expunge_files.txt"
1616+
ansible.builtin.stat:
1617+
path: "{{ fstests_results_target }}/new_expunge_files.txt"
16081618
delegate_to: localhost
16091619
register: new_expunge_files_stat
16101620
run_once: true

playbooks/roles/gitr/tasks/main.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,17 @@
2929
gitr_run_uniqifier: "{{ ansible_date_time.iso8601_basic_short }}"
3030

3131
- name: Clean up our localhost results/last-run directory
32-
ansible.builtin.file: path="{{ gitr_results_target }}/" state=absent
32+
ansible.builtin.file:
33+
path: "{{ gitr_results_target }}/"
34+
state: absent
3335
delegate_to: localhost
3436
run_once: true
3537
tags: ["run_tests", "copy_results", "clean_local_results"]
3638

3739
- name: Create empty last-run directory
38-
ansible.builtin.file: path="{{ gitr_results_target }}/" state=directory
40+
ansible.builtin.file:
41+
path: "{{ gitr_results_target }}/"
42+
state: directory
3943
delegate_to: localhost
4044
run_once: true
4145
tags: ["run_tests", "copy_results", "clean_local_results"]

playbooks/roles/hypervisor-tuning/tasks/main.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
become: true
1717
become_flags: "su - -c"
1818
become_method: sudo
19-
ansible.builtin.stat: path=/sys/kernel/mm/ksm/run
19+
ansible.builtin.stat:
20+
path: /sys/kernel/mm/ksm/run
2021
register: ksm_enable_file
2122
tags: ["hypervisor"]
2223

@@ -33,15 +34,17 @@
3334
become: true
3435
become_flags: "su - -c"
3536
become_method: sudo
36-
ansible.builtin.stat: path=/sys/module/zswap/parameters/enabled
37+
ansible.builtin.stat:
38+
path: /sys/module/zswap/parameters/enabled
3739
register: zswap_enable_file
3840
tags: ["hypervisor"]
3941

4042
- name: Check to see if zswap max pool percent file exists /sys/module/zswap/parameters/max_pool_percent
4143
become: true
4244
become_flags: "su - -c"
4345
become_method: sudo
44-
ansible.builtin.stat: path=/sys/module/zswap/parameters/max_pool_percent
46+
ansible.builtin.stat:
47+
path: /sys/module/zswap/parameters/max_pool_percent
4548
register: zswap_max_pool_percent_file
4649
when:
4750
- hypervisor_tunning_zswap_enable|bool

playbooks/roles/ltp/tasks/main.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,17 @@
3333
run_once: true
3434

3535
- name: Clean up our localhost results/last-run directory
36-
ansible.builtin.file: path="{{ ltp_results_target }}/" state=absent
36+
ansible.builtin.file:
37+
path: "{{ ltp_results_target }}/"
38+
state: absent
3739
delegate_to: localhost
3840
run_once: true
3941
tags: ["run_tests", "copy_results", "clean_local_results"]
4042

4143
- name: Create empty last-run directory
42-
ansible.builtin.file: path="{{ ltp_results_target }}/" state=directory
44+
ansible.builtin.file:
45+
path: "{{ ltp_results_target }}/"
46+
state: directory
4347
delegate_to: localhost
4448
run_once: true
4549
tags: ["run_tests", "copy_results", "clean_local_results"]

0 commit comments

Comments
 (0)