Merge "Disable elasticsearch output when enable_elasticsearch is no in fluentd"
This commit is contained in:
commit
a0d2962f48
@ -35,11 +35,15 @@
|
|||||||
|
|
||||||
- name: Copying over fluentd ouput config files
|
- name: Copying over fluentd ouput config files
|
||||||
template:
|
template:
|
||||||
src: "conf/output/{{ item }}.conf.j2"
|
src: "conf/output/{{ item.name }}.conf.j2"
|
||||||
dest: "{{ node_config_directory }}/fluentd/output/{{ item }}.conf"
|
dest: "{{ node_config_directory }}/fluentd/output/{{ item.name }}.conf"
|
||||||
|
when: item.enabled | bool
|
||||||
with_items:
|
with_items:
|
||||||
- "00-local"
|
- name: "00-local"
|
||||||
- "01-es"
|
enabled: true
|
||||||
|
- name: "01-es"
|
||||||
|
enabled: "{{ enable_elasticsearch }}"
|
||||||
|
|
||||||
- name: Copying over fluentd format config files
|
- name: Copying over fluentd format config files
|
||||||
template:
|
template:
|
||||||
src: "conf/format/{{ item }}.conf.j2"
|
src: "conf/format/{{ item }}.conf.j2"
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
append true
|
append true
|
||||||
compress gzip
|
compress gzip
|
||||||
</store>
|
</store>
|
||||||
|
{% if enable_elasticsearch | bool %}
|
||||||
<store>
|
<store>
|
||||||
type elasticsearch
|
type elasticsearch
|
||||||
host {{ kolla_external_vip_address }}
|
host {{ kolla_external_vip_address }}
|
||||||
@ -16,6 +17,7 @@
|
|||||||
logstash_prefix flog
|
logstash_prefix flog
|
||||||
flush_interval 15s
|
flush_interval 15s
|
||||||
</store>
|
</store>
|
||||||
|
{% endif %}
|
||||||
</match>
|
</match>
|
||||||
|
|
||||||
<match syslog.local1.**>
|
<match syslog.local1.**>
|
||||||
@ -30,6 +32,7 @@
|
|||||||
append true
|
append true
|
||||||
compress gzip
|
compress gzip
|
||||||
</store>
|
</store>
|
||||||
|
{% if enable_elasticsearch | bool %}
|
||||||
<store>
|
<store>
|
||||||
type elasticsearch
|
type elasticsearch
|
||||||
host {{ kolla_external_vip_address }}
|
host {{ kolla_external_vip_address }}
|
||||||
@ -38,4 +41,5 @@
|
|||||||
logstash_prefix flog
|
logstash_prefix flog
|
||||||
flush_interval 15s
|
flush_interval 15s
|
||||||
</store>
|
</store>
|
||||||
|
{% endif %}
|
||||||
</match>
|
</match>
|
||||||
|
@ -60,13 +60,13 @@
|
|||||||
"dest": "/etc/td-agent/format/wsgi_python.conf",
|
"dest": "/etc/td-agent/format/wsgi_python.conf",
|
||||||
"owner": "td-agent",
|
"owner": "td-agent",
|
||||||
"perm": "0600"
|
"perm": "0600"
|
||||||
},
|
},{% if enable_elasticsearch | bool %}
|
||||||
{
|
{
|
||||||
"source": "{{ container_config_directory }}/output/01-es.conf",
|
"source": "{{ container_config_directory }}/output/01-es.conf",
|
||||||
"dest": "/etc/td-agent/output/01-es.conf",
|
"dest": "/etc/td-agent/output/01-es.conf",
|
||||||
"owner": "td-agent",
|
"owner": "td-agent",
|
||||||
"perm": "0600"
|
"perm": "0600"
|
||||||
},
|
},{% endif %}
|
||||||
{
|
{
|
||||||
"source": "{{ container_config_directory }}/output/00-local.conf",
|
"source": "{{ container_config_directory }}/output/00-local.conf",
|
||||||
"dest": "/etc/td-agent/output/00-local.conf",
|
"dest": "/etc/td-agent/output/00-local.conf",
|
||||||
|
Loading…
Reference in New Issue
Block a user