use loop for package names

Signed-off-by: Martin Schurz <Martin.Schurz@telekom.de>
This commit is contained in:
Martin Schurz 2024-02-04 21:50:41 +01:00
parent 898bf73178
commit a0abefbc29

View file

@ -24,11 +24,12 @@
- name: Block update of Grub and kernel, because of error
ansible.builtin.dpkg_selections:
name:
- grub-pc
- linux-image-generic
name: "{{ item }}"
selection: hold
when: ansible_os_family == 'Debian'
loop:
- grub-pc
- linux-image-generic
- name: Run the equivalent of "apt-get update && apt-get upgrade"
ansible.builtin.apt: