You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
76 lines
1.9 KiB
YAML
76 lines
1.9 KiB
YAML
---
|
|
|
|
### tags:
|
|
### update_certs
|
|
### update_config
|
|
### update_deployment
|
|
|
|
- name: "Check if filebeat/docker-compose.yml exists"
|
|
stat:
|
|
path: '{{ service_base_path }}/filebeat/docker-compose.yml'
|
|
register: check_docker_compose_file
|
|
tags:
|
|
- update_config
|
|
- update_deployment
|
|
|
|
- name: "Stop filebeat"
|
|
community.docker.docker_compose:
|
|
project_src: '{{ service_base_path }}/filebeat'
|
|
state: absent
|
|
when: check_docker_compose_file.stat.exists
|
|
tags:
|
|
- update_config
|
|
- update_deployment
|
|
|
|
- name: "Deploy docker templates for filebeat"
|
|
include_role:
|
|
name: sma_deploy
|
|
tasks_from: templates
|
|
vars:
|
|
current_config: "_docker"
|
|
current_base_path: "{{ service_base_path }}"
|
|
current_destination: "filebeat"
|
|
current_owner: "{{ docker_owner }}"
|
|
current_group: "{{ docker_group }}"
|
|
current_docker: "{{ filebeat_docker }}"
|
|
tags:
|
|
- update_config
|
|
- update_deployment
|
|
|
|
- name: "Deploy service templates for filebeat"
|
|
include_role:
|
|
name: sma_deploy
|
|
tasks_from: templates
|
|
vars:
|
|
current_config: "filebeat"
|
|
current_base_path: "{{ service_base_path }}"
|
|
current_destination: "filebeat"
|
|
current_owner: "{{ docker_owner }}"
|
|
current_group: "{{ docker_group }}"
|
|
tags:
|
|
- update_config
|
|
|
|
- name: "Deploy certificate templates for filebeat"
|
|
include_role:
|
|
name: sma_deploy
|
|
tasks_from: templates
|
|
vars:
|
|
current_config: "elastic-certs/{{ stage }}-certs"
|
|
current_base_path: "{{ service_base_path }}"
|
|
current_destination: "filebeat/certs"
|
|
current_owner: "{{ docker_owner }}"
|
|
current_group: "{{ docker_group }}"
|
|
cleanup_destination: "true"
|
|
tags:
|
|
- update_certs
|
|
- update_config
|
|
|
|
- name: "Update filebeat"
|
|
community.docker.docker_compose:
|
|
project_src: '{{ service_base_path }}/filebeat'
|
|
state: present
|
|
pull: yes
|
|
tags:
|
|
- update_config
|
|
- update_deployment
|