| {%- load_yaml as base_defaults %} |
| Debian: |
| pkgs: |
| - elasticsearch |
| dependency_pkgs: |
| - default-jre-headless |
| curator_pkgs: |
| - elasticsearch-curator |
| - cron |
| service: elasticsearch |
| RedHat: |
| pkgs: |
| - elasticsearch |
| dependency_pkgs: |
| - java-1.8.0-openjdk-headless |
| curator_pkgs: |
| - elasticsearch-curator |
| service: elasticsearch |
| {%- endload %} |
| |
| {%- set server = salt['grains.filter_by'](base_defaults, merge=salt['pillar.get']('elasticsearch:server'), base='default') %} |
| |
| {%- load_yaml as client_defaults %} |
| Debian: |
| pkgs: |
| - python-elasticsearch |
| server: |
| host: 127.0.0.1 |
| port: 9200 |
| scheme: http |
| binary_port: 9300 |
| RedHat: |
| pkgs: |
| - python-elasticsearch |
| server: |
| host: 127.0.0.1 |
| port: 9200 |
| scheme: http |
| binary_port: 9300 |
| {%- endload %} |
| |
| {%- set client = salt['grains.filter_by'](client_defaults, merge=salt['pillar.get']('elasticsearch:client')) %} |
| |
| {% set monitoring = salt['grains.filter_by']({ |
| 'default': { |
| 'service_failed_warning_threshold_percent': 0.3, |
| 'service_failed_critical_threshold_percent': 0.6, |
| 'service_disk_space_watermark_minor_threshold_percent': 0.6, |
| 'service_disk_space_watermark_major_threshold_percent': 0.75, |
| }, |
| }, grain='os_family', merge=salt['pillar.get']('elasticsearch:monitoring')) %} |