Merge pull request #311 from companieshouse/master
Ensure elasticsearch is always started and fix yum proxy logic
This commit is contained in:
commit
8f9314b312
2 changed files with 4 additions and 2 deletions
|
|
@ -44,6 +44,9 @@
|
||||||
|
|
||||||
- meta: flush_handlers
|
- meta: flush_handlers
|
||||||
|
|
||||||
|
- name: Make sure elasticsearch is started
|
||||||
|
service: name={{instance_init_script | basename}} state=started enabled=yes
|
||||||
|
|
||||||
- name: Wait for elasticsearch to startup
|
- name: Wait for elasticsearch to startup
|
||||||
wait_for: host={{es_api_host}} port={{es_api_port}} delay=5 connect_timeout=1
|
wait_for: host={{es_api_host}} port={{es_api_port}} delay=5 connect_timeout=1
|
||||||
when: es_restarted is defined and es_restarted.changed
|
when: es_restarted is defined and es_restarted.changed
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,6 @@ baseurl=https://artifacts.elastic.co/packages/{{ es_major_version }}/yum
|
||||||
gpgcheck=1
|
gpgcheck=1
|
||||||
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
|
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
|
||||||
enabled=1
|
enabled=1
|
||||||
{% if es_proxy_host is defined and es_proxy_port is defined %}
|
{% if es_proxy_host is defined and es_proxy_host != '' and es_proxy_port is defined %}
|
||||||
proxy=http://{{ es_proxy_host }}:{{es_proxy_port}}
|
proxy=http://{{ es_proxy_host }}:{{es_proxy_port}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue