Skip to content
Snippets Groups Projects
Commit c2d368d1 authored by Hannes Braun's avatar Hannes Braun :upside_down:
Browse files

add check for undefined variables

parent e92d15df
Branches
Tags
No related merge requests found
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
name: "{{ item.groups }}" name: "{{ item.groups }}"
state: present state: present
with_items: "{{ human_users }}" with_items: "{{ human_users }}"
when: ( item.groups is defined )
become: true become: true
- name: Make sure extra groups exist - name: Make sure extra groups exist
...@@ -11,6 +12,7 @@ ...@@ -11,6 +12,7 @@
name: "{{ item.extra_groups }}" name: "{{ item.extra_groups }}"
state: present state: present
with_items: "{{ human_users }}" with_items: "{{ human_users }}"
when: ( item.extra_groups is defined )
become: true become: true
- name: Create user accounts - name: Create user accounts
...@@ -36,6 +38,7 @@ ...@@ -36,6 +38,7 @@
groups: "{{ item.extra_groups }}" groups: "{{ item.extra_groups }}"
append: true append: true
with_items: "{{ human_users }}" with_items: "{{ human_users }}"
when: ( item.extra_groups is defined )
become: true become: true
- name: Delete absent user accounts - name: Delete absent user accounts
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment