Skip to content

Commit

Permalink
Add max_procs directive
Browse files Browse the repository at this point in the history
Connect to elasticsearch behind basic auth
  • Loading branch information
bsedin committed Aug 12, 2019
1 parent db13407 commit 2bd1f31
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 8 deletions.
5 changes: 4 additions & 1 deletion defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,11 @@ elastic_metricbeat_kibana_port: '{{ elastic_beats_kibana_port }}'
elastic_metricbeat_kibana_basic_auth_username: '{{ elastic_beats_kibana_basic_auth_username }}'
elastic_metricbeat_kibana_basic_auth_password: '{{ elastic_beats_kibana_basic_auth_password }}'
elastic_metricbeat_beat_name: '{{ hostname }}'
elastic_metricbeat_compression_level: 5
elastic_metricbeat_output_elasticsearch_compression_level: 5
elastic_metricbeat_index: metricbeat-%{[agent.version]}-%{+yyyy.MM.dd}
elastic_metricbeat_output_elasticsearch_workers: 1
elastic_metricbeat_output_elasticsearch_bulk_max_size: 50
elastic_metricbeat_template_enabled: 'true'
elastic_metricbeat_template_name: metricbeat
elastic_metricbeat_template_pattern: metricbeat-*
elastic_metricbeat_max_procs: 4
7 changes: 5 additions & 2 deletions templates/filebeat.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@ setup.template.name: '{{ elastic_filebeat_template_name }}'
setup.template.pattern: '{{ elastic_filebeat_template_pattern }}'

output.elasticsearch:
hosts:
{{ elastic_filebeat_elasticsearch_hosts | to_yaml | indent(4) }}
hosts: {{ elastic_filebeat_elasticsearch_hosts | to_yaml }}
{% if elastic_filebeat_elasticsearch_username is defined %}username: {{ elastic_filebeat_elasticsearch_username }}{% endif%}

{% if elastic_filebeat_elasticsearch_password is defined %}password: {{ elastic_filebeat_elasticsearch_password }}{% endif%}

compression_level: {{ elastic_filebeat_compression_level }}
index: {{ elastic_filebeat_index }}

Expand Down
7 changes: 5 additions & 2 deletions templates/heartbeat.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,11 @@ setup.template.name: '{{ elastic_heartbeat_template_name }}'
setup.template.pattern: '{{ elastic_heartbeat_template_pattern }}'

output.elasticsearch:
hosts:
{{ elastic_heartbeat_elasticsearch_hosts | to_yaml | indent(4) }}
hosts: {{ elastic_heartbeat_elasticsearch_hosts | to_yaml }}
{% if elastic_heartbeat_elasticsearch_username is defined %}username: {{ elastic_heartbeat_elasticsearch_username }}{% endif%}

{% if elastic_heartbeat_elasticsearch_password is defined %}password: {{ elastic_heartbeat_elasticsearch_password }}{% endif%}

compression_level: {{ elastic_heartbeat_compression_level }}
index: {{ elastic_heartbeat_index }}

Expand Down
16 changes: 13 additions & 3 deletions templates/metricbeat.yml.j2
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: '{{ elastic_metricbeat_beat_name }}'

logging.level: info
logging.metrics.enabled: true

{% if elastic_metricbeat_kibana_enabled %}
setup.kibana.host: '{{ elastic_metricbeat_kibana_protocol }}://{% if elastic_metricbeat_kibana_basic_auth_username %}{{ elastic_metricbeat_kibana_basic_auth_username }}:{{ elastic_metricbeat_kibana_basic_auth_password }}@{% endif %}{{ elastic_metricbeat_kibana_host }}:{{ elastic_metricbeat_kibana_port }}'
setup.kibana.protocol: '{{ elastic_metricbeat_kibana_protocol }}'
Expand All @@ -14,13 +17,20 @@ setup.template.name: '{{ elastic_metricbeat_template_name }}'
setup.template.pattern: '{{ elastic_metricbeat_template_pattern }}'

output.elasticsearch:
hosts:
{{ elastic_metricbeat_elasticsearch_hosts | to_yaml | indent(4) }}
compression_level: {{ elastic_metricbeat_compression_level }}
hosts: {{ elastic_metricbeat_elasticsearch_hosts | to_yaml }}
{% if elastic_metricbeat_elasticsearch_username is defined %}username: {{ elastic_metricbeat_elasticsearch_username }}{% endif%}

{% if elastic_metricbeat_elasticsearch_password is defined %}password: {{ elastic_metricbeat_elasticsearch_password }}{% endif%}

compression_level: {{ elastic_metricbeat_output_elasticsearch_compression_level }}
index: {{ elastic_metricbeat_index }}
workers: {{ elastic_metricbeat_output_elasticsearch_workers }}
bulk_max_size: {{ elastic_metricbeat_output_elasticsearch_bulk_max_size }}

xpack.monitoring:
enabled: true

metricbeat.modules:
{{ elastic_metricbeat_modules | to_yaml | indent(2) }}

max_procs: {{ elastic_metricbeat_max_procs }}

0 comments on commit 2bd1f31

Please sign in to comment.