---
# file: roles/common/tasks/user.yml
- name: Create system groups
  group:
    name: "{{ item }}"
    system: yes
  with_items:
    - docker
    - "{{ grp_sudo }}"
    - mail
  tags:
    - configuration

- name: Create user-private group
  group:
    name: "{{ user }}"
    system: no
  tags:
    - configuration

- name: Create user account
  user:
    name: "{{ user }}"
    comment: "{{ fullname }}"
    home: "{{ homedir }}"
    createhome: no
    group: "{{ user }}"
    groups: "docker,{{ grp_sudo }},mail"
    password: "{{ user_password }}"
  tags:
    - configuration

- include: home.yml

---
# file: roles/common/tasks/user.yml
- name: Create system groups
  group:
    name: "{{ item }}"
    system: yes
  with_items:
    - docker
    - "{{ grp_sudo }}"
    - mail
  tags:
    - configuration

- name: Create user-private group
  group:
    name: "{{ user }}"
    system: no
  tags:
    - configuration

- name: Create user account
  user:
    name: "{{ user }}"
    comment: "{{ fullname }}"
    home: "{{ homedir }}"
    createhome: no
    group: "{{ user }}"
    groups: "docker,{{ grp_sudo }},mail"
    password: "{{ user_password }}"
  tags:
    - configuration

- import_tasks: home.yml

Replace deprecated include: with import_tasks:
Replace deprecated include: with import_tasks:
