All Projects → geerlingguy → ansible-role-elasticsearch-curator

geerlingguy / ansible-role-elasticsearch-curator

Licence: MIT license
Ansible Role - Elasticsearch Curator

Projects that are alternatives of or similar to ansible-role-elasticsearch-curator

Ansible Role Logstash
Ansible Role - Logstash
Stars: ✭ 136 (+338.71%)
Mutual labels:  elk, role
fluent-plugin-cloudwatch-ingest
Alternative to ryotarai/fluent-plugin-cloudwatch-logs for ingesting AWS Cloudwatch logs via fluentd
Stars: ✭ 11 (-64.52%)
Mutual labels:  elk, efk
ansible-role-elasticsearch
Ansible Role - Elasticsearch
Stars: ✭ 144 (+364.52%)
Mutual labels:  elk, role
ansible-role-kibana
Ansible Role - Kibana
Stars: ✭ 104 (+235.48%)
Mutual labels:  elk, role
gymbox-bot
Simplify the booking of a gymbox class.
Stars: ✭ 21 (-32.26%)
Mutual labels:  cron
rhythm
Time-based job scheduler for Apache Mesos
Stars: ✭ 30 (-3.23%)
Mutual labels:  cron
cronode
Cron for Node.js with expressive code
Stars: ✭ 15 (-51.61%)
Mutual labels:  cron
objection-authorize
isomorphic, "magical" authorization integration with Objection.js 🎉
Stars: ✭ 71 (+129.03%)
Mutual labels:  role
GnusSolution
A complete working solution of gnus+offlineimap+dovecot+msmtp+cron
Stars: ✭ 18 (-41.94%)
Mutual labels:  cron
ansible-role-glusterfs
Ansible Role - GlusterFS
Stars: ✭ 95 (+206.45%)
Mutual labels:  role
cron-time
Javascript Cron Time Expressions
Stars: ✭ 58 (+87.1%)
Mutual labels:  cron
jobs.config
Scheduling recurring jobs.config builder/validator for Velo by Wix
Stars: ✭ 18 (-41.94%)
Mutual labels:  cron
elasticstack
ELK : elasticsearch + logstash + kibana
Stars: ✭ 18 (-41.94%)
Mutual labels:  elk
delayed-notifications-for-gravity-forms
Set delayed notifications for your gravity forms in easy steps
Stars: ✭ 26 (-16.13%)
Mutual labels:  cron
MyDocs
文档类项目,目前自己技术研究日常所需的文档,自己写的文档汇总
Stars: ✭ 76 (+145.16%)
Mutual labels:  elk
ansible-role-phpmyadmin
Ansible Role - phpMyAdmin
Stars: ✭ 40 (+29.03%)
Mutual labels:  role
ansible-role-passenger
Ansible Role - Passenger with Nginx
Stars: ✭ 26 (-16.13%)
Mutual labels:  role
cognipy
In-memory Graph Database and Knowledge Graph with Natural Language Interface, compatible with Pandas
Stars: ✭ 31 (+0%)
Mutual labels:  elk
ansible-role-drupal
Ansible Role - Drupal
Stars: ✭ 80 (+158.06%)
Mutual labels:  role
data-processing-with-logstash
Contains the configuration files used within the Data Processing with Logstash course.
Stars: ✭ 76 (+145.16%)
Mutual labels:  elk

Ansible Role: Elasticsearch Curator

CI

An Ansible Role that installs Elasticsearch Curator on RedHat/CentOS or Debian/Ubuntu.

Requirements

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.

Role Variables

Available variables are listed below, along with default values (see defaults/main.yml):

elasticsearch_curator_version: ''

The version of elasticsearch-curator to install. Available versions are listed on the Python Package Index. By default, no version is specified, so the latest version will be installed.

elasticsearch_curator_cron_jobs:
  - name: "Run elasticsearch curator actions."
    job: "/usr/local/bin/curator ~/.curator/action.yml"
    minute: 0
    hour: 1

A list of cron jobs. Typically you would run one cron job using the actions defined in action.yml, but you can split up cron jobs or use the curator_cli to run actions individually instead of via an action file. You can add any of minute, hour, day, weekday, and month to the cron jobs—values that are not explicitly set will default to *. You can also use state to define whether the job should be present or absent.

elasticsearch_curator_config_directory: ~/.curator

The directory inside which Curator's configuration (and action file) will be stored.

elasticsearch_curator_hosts:
  - 'localhost:9200'
elasticsearch_curator_http_auth: ''

These variables control parameters used in the default elasticsearch_curator_yaml. If you define your own custom elasticsearch_curator_yaml, you may not need to define or override these variables. _hosts is a list of hosts with ports, and _http_auth is a basic http_auth user:pass string, if your Elasticsearch instance requires basic HTTP authorization.

elasticsearch_curator_yaml: |
  ---
  client:
    hosts: {{ elasticsearch_curator_hosts | to_yaml }}
    url_prefix:
    use_ssl: False
    certificate:
    client_cert:
    client_key:
    ssl_no_validate: False
    http_auth: {{ elasticsearch_curator_http_auth }}
    timeout: 30
    master_only: False
  logging:
    loglevel: INFO
    logfile:
    logformat: default
    blacklist: ['elasticsearch', 'urllib3']

This YAML goes into the file ~/.curator/curator.yml and stores the connection details Elasticsearch Curator uses to when connecting to Elasticsearch, as well as Curator logging configuration.

elasticsearch_curator_action_yaml: |
  ---
  actions:
    1:
      action: delete_indices
      options:
        ignore_empty_list: True
        disable_action: False
      filters:
      - filtertype: pattern
        kind: prefix
        value: logstash-
        exclude:
      - filtertype: age
        source: name
        direction: older
        timestring: '%Y.%m.%d'
        unit: days
        unit_count: 45
        exclude:

This YAML goes into the file ~/.curator/action.yml and defines the actions Curator performs when the default cron job is run. See documentation: Curator actions file.

elasticsearch_curator_pip_package: 'python-pip'

System pip package which needs to be installed. For newer OSes or when using Python 3, you may need to override this and change it to python3-pip.

Dependencies

  • geerlingguy.repo-epel (RedHat/CentOS only)

Example Playbook

- hosts: search
  roles:
    - { role: geerlingguy.elasticsearch-curator }

License

MIT / BSD

Author Information

This role was created in 2014 by Jeff Geerling, author of Ansible for DevOps.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].