apiVersion: v1 kind: ConfigMap metadata: name: fluentd-config namespace: efk data: fluent.conf: | @type http @id input_http port 8888 tag sardine.log @label @main @type rewrite_tag_filter key @timestamp pattern /^(202[4-9]|2[1-9]\d{3})/ tag hot.${tag} key @timestamp pattern /^(202[0-3])/ tag warm.${tag} key @timestamp pattern /^(201\d|200\d|19\d{2})/ tag cold.${tag} @type elasticsearch @id output_elasticsearch_hot hosts elasticsearch-0.elasticsearch-service.efk.svc.cluster.local:9200 scheme http user fluentd_user password fluentd_password logstash_format true logstash_prefix logstash index_date_pattern now/d include_tag_key true tag_key @log_name flush_interval 5s @log_level debug @type elasticsearch @id output_elasticsearch_warm hosts elasticsearch-1.elasticsearch-service.efk.svc.cluster.local:9200 scheme http user fluentd_user password fluentd_password logstash_format true logstash_prefix logstash index_date_pattern now/d include_tag_key true tag_key @log_name flush_interval 10s @log_level debug @type elasticsearch @id output_elasticsearch_cold hosts elasticsearch-2.elasticsearch-service.efk.svc.cluster.local:9200 scheme http user fluentd_user password fluentd_password logstash_format true logstash_prefix logstash index_date_pattern now/d include_tag_key true tag_key @log_name flush_interval 30s @log_level debug @type stdout @id output_stdout_all