passwords
Manage users’ passwords. At the moment only passwordstore
Unix password manager is
implemented.
Passwordstore
Create passwords in passwordstore
and enable access for the user who is running the
playbook. For example
shell> pass build.example.com/
build.example.com
├── admin
└── root
Configure the variables. Enable the management of the users’ passwords (3), select passwordstore
(4), and configure the variable that keeps the name of the host used in passwordstore (5),
ansible_nodename in this case. Next options might be inventory_hostname (default),
ansible_hostname, or any other custom variable. For example
1shell> cat host_vars/build.example.com/fp-passwords.yml
2---
3fp_passwords: true
4fp_passwordstore: true
5fp_passwordstore_hostname_var: ansible_nodename
6...
Dry-run the tasks, display the variables, and display the changes
shell> ansible-playbook playbook.yml -t fp_passwords -e fp_passwords_debug=true -CD
If all seems to be right manage the users’ passwords
shell> ansible-playbook playbook.yml -t fp_passwords
See also
Annotated Source code passwords.yml
Project website passwordstore.org