Skip to content
Extraits de code Groupes Projets
Valider e7a09fc0 rédigé par Rémi - Le Filament's avatar Rémi - Le Filament
Parcourir les fichiers

[FIX] some modules do not loop through list

parent f3c0a676
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
- name: Include OS-specific variables. - name: Include OS-specific variables.
include_vars: "{{ ansible_os_family }}.yml" include_vars: "{{ ansible_os_family }}.yml"
- name: Correct the machine hostname to "{{ inventory_hostname_short }}" - name: Set machine hostname
hostname: name="{{ inventory_hostname_short | lower | regex_replace('_','') }}" hostname: name="{{ inventory_hostname_short | lower | regex_replace('_','') }}"
- name: Debian Update repo and upgrade installed packages - name: Debian Update repo and upgrade installed packages
...@@ -42,15 +42,17 @@ ...@@ -42,15 +42,17 @@
- name: Remove unecessary files if present - name: Remove unecessary files if present
file: file:
path: "{{ files_to_remove }}" path: "{{ item }}"
state: absent state: absent
when: ansible_os_family == "Debian" when: ansible_os_family == "Debian"
with_items: "{{ files_to_remove }}"
- name: Remove unecessary users if present - name: Remove unecessary users if present
user: user:
name: "{{ users_to_remove }}" name: "{{ item }}"
remove: true remove: true
state: absent state: absent
with_items: "{{ users_to_remove }}"
- name: disable dynamic motd news - name: disable dynamic motd news
lineinfile: lineinfile:
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter