An Ansible Role that installs Elasticsearch Curator on RedHat/CentOS or Debian/Ubuntu.
None, but it's a lot more helpful if you have Elasticsearch running somewhere :)
On RedHat/CentOS, make sure you have the EPEL repository configured, so the python-pip
package can be installed. You can install the EPEL repo by simply adding geerlingguy.repo-epel
to your playbook's roles.
Available variables are listed below, along with default values (see defaults/main.yml
):
elasticsearch_curator_cron_jobs:
- {
name: "Delete indices older than 30 days (daily).",
job: "curator delete --older-than 30",
minute: "0",
hour: "1"
}
- {
name: "Close indices older than 14 days (daily).",
job: "curator close --older-than 14",
minute: "30",
hour: "1"
}
A list of cron jobs to use curator to prune, optimize, close, and otherwise maintain your Elasticsearch indexes. If you're connecting to an Elasticsearch server on a different host/port than localhost
and 9200
, you need to add --host [hostname]
and/or --port [port]
to the jobs. More documentation is available on the Elasticsearch Curator wiki. You can add any of minute
, hour
, day
, weekday
, and month
to the cron jobs—values that are not explicitly set will default to *
.
- geerlingguy.repo-epel (RedHat/CentOS only)
- hosts: search
roles:
- { role: geerlingguy.elasticsearch-curator }
MIT / BSD
This role was created in 2014 by Jeff Geerling, author of Ansible for DevOps.