Add task to install requirements and change pathing
To run the curator playbook pip is required. This change installs the package `python-virtualenv` to resolve the dependency and installs the curator application into a virtualenv within /opt. This will keep the host clean by isolating the dependencies and ensure that we can easily clean up should we ever need to. Change-Id: If872bb30281948d79a3f79a0e3a39e8a457c6fdb Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
This commit is contained in:
parent
582e5199f3
commit
2207df4622
@ -25,11 +25,22 @@
|
|||||||
environment: "{{ deployment_environment_variables | default({}) }}"
|
environment: "{{ deployment_environment_variables | default({}) }}"
|
||||||
|
|
||||||
pre_tasks:
|
pre_tasks:
|
||||||
|
- name: Ensure virtualenv is installed
|
||||||
|
apt:
|
||||||
|
name: "{{ item }}"
|
||||||
|
state: "present"
|
||||||
|
update_cache: true
|
||||||
|
with_items:
|
||||||
|
- python-virtualenv
|
||||||
|
tags:
|
||||||
|
- package_install
|
||||||
|
|
||||||
- name: Ensure curator is installed
|
- name: Ensure curator is installed
|
||||||
pip:
|
pip:
|
||||||
name: elasticsearch-curator
|
name: "elasticsearch-curator<6"
|
||||||
state: "{{ elk_package_state | default('present') }}"
|
state: "{{ elk_package_state | default('present') }}"
|
||||||
extra_args: --isolated
|
extra_args: --isolated
|
||||||
|
virtualenv: /opt/elasticsearch-curator
|
||||||
|
|
||||||
- name: exit playbook after uninstall
|
- name: exit playbook after uninstall
|
||||||
meta: end_play
|
meta: end_play
|
||||||
@ -87,7 +98,7 @@
|
|||||||
systemd_services:
|
systemd_services:
|
||||||
- service_name: "curator"
|
- service_name: "curator"
|
||||||
execstarts:
|
execstarts:
|
||||||
- /usr/local/bin/curator
|
- /opt/elasticsearch-curator/bin/curator
|
||||||
--config /var/lib/curator/curator.yml
|
--config /var/lib/curator/curator.yml
|
||||||
/var/lib/curator/actions.yml
|
/var/lib/curator/actions.yml
|
||||||
timer:
|
timer:
|
||||||
|
Loading…
Reference in New Issue
Block a user