linter applied to file

This commit is contained in:
Lukas Greve
2025-11-13 20:37:21 +01:00
parent 8f8d56eae7
commit 1a523b843c

View File

@@ -1,25 +1,25 @@
---
- name: Update system packages
hosts: gitrunner
become: yes
become: true
tasks:
- name: Update system packages
yum:
ansible.builtin.dnf:
name: "*"
state: latest
update_cache: yes
update_cache: true
- name: Check if reboot required (RedHat/CentOS)
command: needs-restarting -r
ansible.builtin.command: needs-restarting -r
register: needs_restarting_output
changed_when: false
ignore_errors: true
when: ansible_os_family == "RedHat"
- name: Reboot if required (RedHat/CentOS)
reboot:
when:
ansible.builtin.reboot:
when:
- ansible_os_family == "RedHat"
- needs_restarting_output.rc == 1
- needs_restarting_output is defined
- needs_restarting_output is defined