Created
July 14, 2019 22:36
-
-
Save 0sc/c5d88f58aafca0c3b507c69589fcd6e3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: ConfigMap | |
metadata: | |
name: fluentd-logging | |
namespace: kube-system | |
labels: | |
app: fluentd-logging | |
data: | |
fluent.conf: | | |
<source> | |
@type tail | |
path /var/log/*.log | |
pos_file /var/log/fluentd/tmp/access.log.pos | |
tag foo.* | |
<parse> | |
@type json | |
</parse> | |
</source> | |
<source> | |
@type tail | |
@id in_tail_container_logs | |
path /var/log/containers/*.log | |
pos_file /var/log/fluentd-containers.log.pos | |
tag kubernetes.* | |
read_from_head true | |
<parse> | |
@type json | |
time_format %Y-%m-%dT%H:%M:%S.%NZ | |
</parse> | |
</source> | |
<match fluentd.**> | |
@type null | |
</match> | |
<match kubernetes.var.log.containers.**fluentd**.log> | |
@type null | |
</match> | |
<filter kubernetes.**> | |
@type kubernetes_metadata | |
@id filter_kube_metadata | |
</filter> | |
<match kubernetes.var.log.containers.**> | |
@type stdout | |
</match> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment