From 91979e7e8c0da2ccb130b13e680b5a60bb4b6d0c Mon Sep 17 00:00:00 2001 From: Lee VanGinkel Date: Fri, 15 Sep 2023 11:49:41 -0400 Subject: [PATCH] update elastic --- roles/telemetry/tasks/update_elastic.yml | 26 ++++++++---------------- 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/roles/telemetry/tasks/update_elastic.yml b/roles/telemetry/tasks/update_elastic.yml index eafbeca..43f2543 100644 --- a/roles/telemetry/tasks/update_elastic.yml +++ b/roles/telemetry/tasks/update_elastic.yml @@ -1,24 +1,14 @@ --- -- name: Docker Compose Down - docker_compose: - project_src: "{{ telemetry_base_dir }}" - state: absent - -# Wait for 5 seconds for docker container to go down -- name: Pause to allow containers to boot up - pause: - seconds: 5 - -- name: Update filebeat config file - copy: - content: "{{ filebeat_template }}" +- name: Copy filebeat file + ansible.builtin.template: + src: "{{ mdd_telemetry }}/filebeat.yml.j2" dest: "{{ telemetry_base_dir }}/filebeat.yml" - force: true + mode: 0600 -- name: Docker Compose Up - docker_compose: - project_src: "{{ telemetry_base_dir }}" - state: present +- name: Restart ELK Stack containers + command: docker compose restart + args: + chdir: "{{ telemetry_base_dir }}" - name: Check container state docker_container_info: