Skip to main content

User Role

Manage a local user account and its SSH authorized keys.


Variables​

VariableTypeOptionsDefaultDescription
userlist of dict---list of user accounts to manage
user.user_usernamestring---login name
user.user_statestringpresent, absentwhether the user exists
user.user_passwordstring---plaintext password (hashed at runtime)
user.user_sudo_pwlessbooltrue, falsegrant passwordless sudo
user.user_groupslist of string---supplementary groups
user.user_homebooltrue, falsecreate home directory
user.user_shellstring---login shell
user.user_commentstring---GECOS comment field
user.user_publist of string---SSH public keys to add to authorized_keys
user.user_install_key_to_targetsbooltrue, falsealso install keys on user_key_target_users
user_key_target_userslist of string---["root"]list of users that receive all user SSH public keys