ansible-role-kibana/tasks/main.yml

47 lines
922 B
YAML
Raw Normal View History

2019-09-06 04:57:24 +00:00
---
- name: install dependencies packages
apt:
name: apt-transport-https
retries: 2
register: result
until: result is succeeded
tags: kibana
- name: add repository key
apt_key:
url: https://artifacts.elastic.co/GPG-KEY-elasticsearch
retries: 2
register: result
until: result is succeeded
tags: kibana
- name: add repository
apt_repository:
repo: 'deb https://artifacts.elastic.co/packages/{{ kibana_major_version }}.x/apt stable main'
tags: kibana
- name: install package
apt:
name: kibana
retries: 2
register: result
until: result is succeeded
tags: kibana
- name: copy config file
copy:
content: '{{ kibana_config|to_yaml }}'
dest: /etc/kibana/kibana.yml
owner: root
group: root
mode: 0644
notify: restart kibana
tags: kibana
- name: enable and start service
systemd:
name: kibana
state: started
enabled: true
tags: kibana