You've already forked ansible-role-unix-users
Initial Commit
This commit is contained in:
14
tasks/create_unix_group.yml
Normal file
14
tasks/create_unix_group.yml
Normal file
@ -0,0 +1,14 @@
|
||||
---
|
||||
|
||||
- name: Create unix group {{ unix_group.key }} with random gid
|
||||
group:
|
||||
name: "{{ unix_group.key }}"
|
||||
state: "{{ unix_group.value.state | default('present') }}"
|
||||
when: unix_group.value.gid is not defined or unix_group.value.gid is defined and unix_group.value.gid == ""
|
||||
|
||||
- name: Create unix group {{ unix_group.key }} with pre-defined gid
|
||||
group:
|
||||
name: "{{ unix_group.key }}"
|
||||
gid: "{{ unix_group.value.gid }}"
|
||||
state: "{{ unix_group.value.state | default('present') }}"
|
||||
when: unix_group.value.gid is defined and unix_group.value.gid != ""
|
Reference in New Issue
Block a user