mirror of
https://github.com/roles-ansible/ansible_role_prometheus_ping_exporter.git
synced 2024-08-16 10:19:51 +02:00
24 lines
638 B
YAML
24 lines
638 B
YAML
|
---
|
||
|
- name: "Create Ping Exporter Group"
|
||
|
become: true
|
||
|
ansible.builtin.group:
|
||
|
name: "{{ ping_exporter__group }}"
|
||
|
system: true
|
||
|
state: "present"
|
||
|
notify:
|
||
|
- "Systemctl restart ping_exporter.service"
|
||
|
|
||
|
- name: "Create Ping Exporter User"
|
||
|
become: true
|
||
|
ansible.builtin.user:
|
||
|
name: "{{ ping_exporter__user }}"
|
||
|
comment: "Ping Exporter User"
|
||
|
group: "{{ ping_exporter__group }}"
|
||
|
groups: "{{ ping_exporter__groups | default(omit) }}"
|
||
|
home: "{{ ping_exporter__user_home }}"
|
||
|
shell: "{{ ping_exporter__shell }}"
|
||
|
system: true
|
||
|
register: _user
|
||
|
notify:
|
||
|
- "Systemctl restart ping_exporter.service"
|