This role's duty is to set up users and groups.
A list of groups to be created.
A dictionary of users to be created, where:
- the key represents the username of the user to be created
- a required key
passwordis the password to be set on user creation — it will not override current user password - an optional key
groupis the primary group of the user - an optional key
groupsis a list of additional groups - an optional key
ssh_keysis a list of public keys to add inauthorized_keysfor SSH access - an optional key
ssh_keys_urlis an URL to which retrieve public keys to add inauthorized_keysfor SSH access - an optional key
generate_ssh_keyis a boolean value to decide if a private/public key pair should be generated for the user - an optional key
ssh_key_publicis a public key to be written in$HOME/.ssh/id_rsa.pub - an optional key
ssh_key_privateis a private key to be written in$HOME/.ssh/id_rsa - an optional key
ps1is the PS1 string to set for the user
---
users_groups:
- sysadmins
- othergroup
users:
fquffio:
password: $6$rounds=656000$6xPefyB0D3dQacsd$/bC.gnd6M.WThGD7dlHrZMSfV3fETYAywhYRqMc09qLSArqKS.EpvVtKaxyI15GSp9AWzuBSNRoLx7vsp5jiq/
ssh_keys_url: https://github.com/fquffio.keys
generate_ssh_key: yes
group: sysadmins
groups:
- othergroup
- sudoIssues and pull requests are more than welcome!
This repo is a split of the main code that can be found here. Please, open pull requests against that repository instead.