Skip to content

Commit

Permalink
Merge pull request #52 from stackhpc/append
Browse files Browse the repository at this point in the history
Support the append argument to the user module
  • Loading branch information
davidpanofsky authored Oct 31, 2017
2 parents f0ee28b + c2446e8 commit 90af956
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ The following attributes are required for each user:
- 'on_create' will only set the password for newly created users.
* group - optional primary group override
* groups - a list of supplementary groups for the user.
* append - if yes, will only add groups, not set them to just the list in groups (optional).
* profile - a string block for setting custom shell profiles
* ssh_key - This should be a list of ssh keys for the user (optional). Each ssh key
should be included directly and should have no newlines.
Expand Down
1 change: 1 addition & 0 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
group: "{{item.group | default(item.username if users_create_per_user_group else users_group)}}"
# empty string removes user from all secondary groups
groups: "{{item.groups | join(',') if 'groups' in item else ''}}"
append: "{{item.append | default(omit)}}"
shell: "{{item.shell if item.shell is defined else users_default_shell}}"
password: "{{item.password if item.password is defined else '!'}}"
comment: "{{item.name if item.name is defined else ''}}"
Expand Down

0 comments on commit 90af956

Please sign in to comment.