diff --git a/tasks/users.yml b/tasks/users.yml index 9805452..47f4bd5 100644 --- a/tasks/users.yml +++ b/tasks/users.yml @@ -4,7 +4,7 @@ ansible.builtin.user: name: "{{ user.username }}" state: "{{ user.state | default('present') }}" - group: "{{ user.group | default(user.username) }}" + group: "{{ user.group | default(omit) }}" groups: "{{ user.groups | default(omit) | join(',') }}" comment: "{{ user.comment | default(omit) }}" shell: "{{ user.shell | default(omit) }}"