86d05ac180
This condition blocks the creation of the `etcd` user in certain conditions. Specifically, when you have a `etcd_deployment_type: kubeadm` and `kube_owner: root`. Being the `root` user already present on the system, this will not be a problem (due to the idempotency of ansible).
16 lines
515 B
YAML
16 lines
515 B
YAML
---
|
|
- name: User | Create User Group
|
|
group:
|
|
name: "{{ user.group|default(user.name) }}"
|
|
system: "{{ user.system|default(omit) }}"
|
|
|
|
- name: User | Create User
|
|
user:
|
|
comment: "{{ user.comment|default(omit) }}"
|
|
createhome: "{{ user.createhome|default(omit) }}"
|
|
group: "{{ user.group|default(user.name) }}"
|
|
home: "{{ user.home|default(omit) }}"
|
|
shell: "{{ user.shell|default(omit) }}"
|
|
name: "{{ user.name }}"
|
|
system: "{{ user.system|default(omit) }}"
|
|
when: user.name != "root"
|