infrastructure/ansible/roles/base/tasks/user.yml

16 lines
316 B
YAML
Raw Normal View History

2020-05-09 20:47:41 +01:00
- name: Make me
user:
name: "{{ user }}"
home: "{{ home }}"
comment: "{{ name }}"
2020-05-10 19:23:41 +01:00
shell: /bin/bash
2020-05-09 20:47:41 +01:00
system: true
become: true
- name: Give user sudo access
user:
name: "{{ user }}"
groups: "{{ 'sudo' if ansible_os_family == 'Debian' else 'wheel' }}"
append: true
2020-05-09 20:47:41 +01:00
become: true