Skip to content

Instantly share code, notes, and snippets.

@gregbuehler
Last active December 23, 2015 09:29
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gregbuehler/6614468 to your computer and use it in GitHub Desktop.
Save gregbuehler/6614468 to your computer and use it in GitHub Desktop.
user script
users:
- { username: user1, password: password }
- { username: user2, password: password }
- { username: user3, password: password }
- { username: user4, password: password }
- name: common | Create users
sudo: yes
user: name={{ item.username }}
group={{ item.username }}
groups=wheel
password={{ item.password }}
update_password=on_create
createhome=yes
home=/home/{{ item.username }}
state=present
with_items:
- users
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment