From 717dd74a9f6c251a706c68ae6da908c3a649315c Mon Sep 17 00:00:00 2001 From: Artem Alexandrov Date: Fri, 25 Mar 2016 11:20:23 +0300 Subject: [PATCH] Removed bare variables Issue #86 --- tasks/elasticsearch-plugins.yml | 6 +++--- tasks/elasticsearch-templates.yml | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tasks/elasticsearch-plugins.yml b/tasks/elasticsearch-plugins.yml index caa7316..e74874f 100644 --- a/tasks/elasticsearch-plugins.yml +++ b/tasks/elasticsearch-plugins.yml @@ -21,7 +21,7 @@ - name: Remove elasticsearch plugins command: "{{es_home}}/bin/plugin remove {{item}} --silent" ignore_errors: yes - with_items: installed_plugins.stdout_lines + with_items: "{{ installed_plugins.stdout_lines }}" when: es_plugins_reinstall and installed_plugins.stdout_lines | length > 0 and not 'No plugin detected' in installed_plugins.stdout_lines[0] notify: restart elasticsearch environment: @@ -42,7 +42,7 @@ register: plugin_installed failed_when: "'Failed to install' in plugin_installed.stderr" changed_when: plugin_installed.rc == 0 - with_items: es_plugins + with_items: "{{ es_plugins }}" when: es_plugins is defined and not es_plugins is none notify: restart elasticsearch environment: @@ -51,4 +51,4 @@ #Set permissions on plugins directory - name: Set Plugin Directory Permissions - file: state=directory path={{ plugin_dir }} owner={{ es_user }} group={{ es_group }} recurse=yes \ No newline at end of file + file: state=directory path={{ plugin_dir }} owner={{ es_user }} group={{ es_group }} recurse=yes diff --git a/tasks/elasticsearch-templates.yml b/tasks/elasticsearch-templates.yml index 0fe3a0f..42bad77 100644 --- a/tasks/elasticsearch-templates.yml +++ b/tasks/elasticsearch-templates.yml @@ -8,7 +8,7 @@ - name: Copy templates to elasticsearch copy: src={{ item }} dest=/etc/elasticsearch/ owner={{ es_user }} group={{ es_group }} - with_fileglob: es_templates_fileglob + with_fileglob: "{{ es_templates_fileglob }}" - set_fact: http_port=9200 @@ -24,4 +24,4 @@ - name: Install template(s) command: "curl -sL -XPUT http://localhost:{{http_port}}/_template/{{item}} -d @/etc/elasticsearch/templates/{{item}}.json" - with_items: resultstemplate.stdout_lines + with_items: "{{ resultstemplate.stdout_lines }}"