Merge pull request #54 from gingerwizard/master

Fix for when plugins are not defined
This commit is contained in:
gingerwizard 2016-01-15 22:22:18 +00:00
commit 5d785413b3
4 changed files with 5 additions and 4 deletions

View file

@ -198,3 +198,4 @@ all supported platforms.
* The role aims to be idempotent. Running the role multiple times, with no changes, should result in no state change on the server. If the configuration is changed, these will be applied and * The role aims to be idempotent. Running the role multiple times, with no changes, should result in no state change on the server. If the configuration is changed, these will be applied and
Elasticsearch restarted where required. Elasticsearch restarted where required.
* Systemd is used for Ubuntu versions >= 15, Debian >=8, Centos >=7. All other versions use init for service scripts. * Systemd is used for Ubuntu versions >= 15, Debian >=8, Centos >=7. All other versions use init for service scripts.

View file

@ -1,4 +1,4 @@
- name: restart elasticsearch - name: restart elasticsearch
service: name={{instance_init_script | basename}} state=restarted enabled=yes service: name={{instance_init_script | basename}} state=restarted enabled=yes
when: es_start_service and (not elasticsearch_started.changed or plugin_installed.changed) when: es_start_service and (not elasticsearch_started.changed or (plugin_installed is defined and plugin_installed.changed))

View file

@ -1,6 +1,5 @@
--- ---
#TODO: How to handle in multi node
# 1. Template directory needs to be specifiable
- name: Copy templates to elasticsearch - name: Copy templates to elasticsearch
copy: src=templates dest=/etc/elasticsearch/ owner={{ es_user }} group={{ es_group }} copy: src=templates dest=/etc/elasticsearch/ owner={{ es_user }} group={{ es_group }}

View file

@ -10,4 +10,5 @@
- include: elasticsearch-scripts.yml - include: elasticsearch-scripts.yml
when: es_scripts when: es_scripts
- include: elasticsearch-templates.yml - include: elasticsearch-templates.yml
when: es_templates when: es_templates
- meta: flush_handlers