Users (users)

Manage users.

Example

Enable management of users (3) and create list of the users (4). For example,

 1 shell> cat host_vars/build.example.com/fp-users.yml
 2 ---
 3 fp_users: true
 4 fp_users_conf:
 5   - name: admin
 6     shell: /bin/sh
 7     groups: [wheel]
 8   - name: responder
 9     shell: /usr/sbin/nologin
10   - name: freebsd
11     state: absent
12 ...

Dry-run the tasks, display the variables, and display the changes

shell> ansible-playbook playbook.yml -t fp_users -e fp_users_debug=true -CD

If all seems to be right, configure the users

shell> ansible-playbook playbook.yml -t fp_users

See also