Commit 4c84c7c1 authored by Jürgen Haas's avatar Jürgen Haas

General improvements

parent c77c1e6e
......@@ -11,12 +11,16 @@
force_basic_auth: yes
status_code: 200
body_format: json
tags:
- Config
- name: Copy snapshot script
template:
src: elasticsearch-snapshot
dest: /usr/local/bin/elasticsearch-snapshot
mode: 0755
tags:
- Config
- name: Backup Cron
cron:
......
......@@ -27,6 +27,10 @@
owner: root
group: elasticsearch
mode: 0644
tags:
- Config
notify:
- Restart Elasticsearch
- name: Uninstall Plugins
elasticsearch_plugin:
......@@ -63,6 +67,10 @@
line: 'xpack.security.transport.ssl.enabled: false'
- regexp: 'path.repo'
line: 'path.repo: ["/var/backups/elasticsearch"]'
tags:
- Config
notify:
- Restart Elasticsearch
- name: Configure JVM options
lineinfile:
......@@ -77,6 +85,10 @@
line: '-Xmx{{ elasticsearch.memory|default("2g") }}'
- line: '-XX:+UseConcMarkSweepGC'
state: absent
tags:
- Config
notify:
- Restart Elasticsearch
- name: Prepare backup directory
file:
......
......@@ -29,6 +29,8 @@
- name: Include backup
include_tasks: backup.yml
tags:
- Config
when: elasticsearch.snapshot is defined and elasticsearch.snapshot.indices is defined
when: not excluded_roles or "elasticsearch" not in excluded_roles
......@@ -27,3 +27,4 @@
with_items: '{{ elasticsearch.purge }}'
tags:
- cron
- Config
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment