From 2519451696de8bb46430c55982997c95d5cf9cd6 Mon Sep 17 00:00:00 2001 From: Duong Mai Date: Sat, 9 Mar 2019 11:46:04 +0700 Subject: [PATCH] Edit ansible script for deploy kibana Kibana deployment failed becaused of kibana_confs variable does not have attribute key, So handlers failed to check conditional kibana_conf.changed | bool becaused of kibana_confs.results|selectattr(item.key) does not exits. Change variable name kibana_confs to kibana_conf. Change-Id: If5e0a25b270a6f05c435a6dc32e2ac49406389c5 Closes-Bug: #1819246 --- ansible/roles/kibana/handlers/main.yml | 1 - ansible/roles/kibana/tasks/config.yml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/ansible/roles/kibana/handlers/main.yml b/ansible/roles/kibana/handlers/main.yml index ea21e0a056..97def7aab2 100644 --- a/ansible/roles/kibana/handlers/main.yml +++ b/ansible/roles/kibana/handlers/main.yml @@ -4,7 +4,6 @@ service_name: "kibana" service: "{{ kibana_services[service_name] }}" config_json: "{{ kibana_config_jsons.results|selectattr('item.key', 'equalto', service_name)|first }}" - kibana_conf: "{{ kibana_confs.results|selectattr('item.key', 'equalto', service_name)|first }}" kibana_container: "{{ check_kibana_containers.results|selectattr('item.key', 'equalto', service_name)|first }}" become: true kolla_docker: diff --git a/ansible/roles/kibana/tasks/config.yml b/ansible/roles/kibana/tasks/config.yml index a19ed359a2..11000f0af8 100644 --- a/ansible/roles/kibana/tasks/config.yml +++ b/ansible/roles/kibana/tasks/config.yml @@ -34,7 +34,7 @@ dest: "{{ node_config_directory }}/kibana/kibana.yml" mode: "0660" become: true - register: kibana_confs + register: kibana_conf with_first_found: - "{{ node_custom_config }}/kibana/{{ inventory_hostname }}/kibana.yml" - "{{ node_custom_config }}/kibana/kibana.yml"