2016-01-22 12:14:09 -08:00
|
|
|
---
|
|
|
|
|
#Add the elasticsearch user before installing from packages.
|
|
|
|
|
- name: Ensure optional elasticsearch group is created with the correct id.
|
2017-05-12 13:31:50 -07:00
|
|
|
become: yes
|
2017-08-20 10:30:39 -04:00
|
|
|
#Restart if these change
|
|
|
|
|
notify: restart elasticsearch
|
2016-01-22 12:14:09 -08:00
|
|
|
group:
|
|
|
|
|
state: present
|
|
|
|
|
name: "{{ es_group }}"
|
|
|
|
|
system: yes
|
|
|
|
|
gid: "{{ es_group_id }}"
|
|
|
|
|
|
|
|
|
|
- name: Ensure optional elasticsearch user is created with the correct id.
|
2017-05-12 13:31:50 -07:00
|
|
|
become: yes
|
2017-08-20 10:30:39 -04:00
|
|
|
#Restart if these change
|
|
|
|
|
notify: restart elasticsearch
|
2016-01-22 12:14:09 -08:00
|
|
|
user:
|
|
|
|
|
state: present
|
|
|
|
|
name: "{{ es_user }}"
|
|
|
|
|
comment: elasticsearch system user
|
|
|
|
|
system: yes
|
|
|
|
|
createhome: no
|
|
|
|
|
uid: "{{ es_user_id }}"
|
|
|
|
|
group: "{{ es_group }}"
|