Skip to content

Instantly share code, notes, and snippets.

@gregbuehler
Last active August 8, 2025 21:05
Show Gist options
  • Select an option

  • Save gregbuehler/6614468 to your computer and use it in GitHub Desktop.

Select an option

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
@v664
Copy link

v664 commented Aug 8, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment