mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 21:17:23 +00:00
Avoid exporting fluentd-gcp own logs
This commit is contained in:
parent
81b3644017
commit
e52c3e77e2
@ -26,7 +26,7 @@
|
|||||||
.PHONY: build push
|
.PHONY: build push
|
||||||
|
|
||||||
PREFIX=gcr.io/google_containers
|
PREFIX=gcr.io/google_containers
|
||||||
TAG = 1.29
|
TAG = 1.30
|
||||||
|
|
||||||
build:
|
build:
|
||||||
docker build -t $(PREFIX)/fluentd-gcp:$(TAG) .
|
docker build -t $(PREFIX)/fluentd-gcp:$(TAG) .
|
||||||
|
@ -26,4 +26,4 @@ fi
|
|||||||
LD_PRELOAD=/opt/td-agent/embedded/lib/libjemalloc.so
|
LD_PRELOAD=/opt/td-agent/embedded/lib/libjemalloc.so
|
||||||
RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=0.9
|
RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=0.9
|
||||||
|
|
||||||
/usr/sbin/td-agent "$@"
|
/usr/sbin/td-agent $@
|
||||||
|
@ -36,8 +36,8 @@ fi
|
|||||||
readonly master_ssh_supported_providers="gce aws kubemark"
|
readonly master_ssh_supported_providers="gce aws kubemark"
|
||||||
readonly node_ssh_supported_providers="gce gke aws"
|
readonly node_ssh_supported_providers="gce gke aws"
|
||||||
|
|
||||||
readonly master_logfiles="kube-apiserver kube-scheduler rescheduler kube-controller-manager etcd glbc cluster-autoscaler kube-addon-manager"
|
readonly master_logfiles="kube-apiserver kube-scheduler rescheduler kube-controller-manager etcd glbc cluster-autoscaler kube-addon-manager fluentd"
|
||||||
readonly node_logfiles="kube-proxy"
|
readonly node_logfiles="kube-proxy fluentd"
|
||||||
readonly aws_logfiles="cloud-init-output"
|
readonly aws_logfiles="cloud-init-output"
|
||||||
readonly gce_logfiles="startupscript"
|
readonly gce_logfiles="startupscript"
|
||||||
readonly kern_logfile="kern"
|
readonly kern_logfile="kern"
|
||||||
|
@ -11,7 +11,16 @@ spec:
|
|||||||
dnsPolicy: Default
|
dnsPolicy: Default
|
||||||
containers:
|
containers:
|
||||||
- name: fluentd-cloud-logging
|
- name: fluentd-cloud-logging
|
||||||
image: gcr.io/google_containers/fluentd-gcp:1.29
|
image: gcr.io/google_containers/fluentd-gcp:1.30
|
||||||
|
# If fluentd consumes its own logs, the following situation may happen:
|
||||||
|
# fluentd fails to send a chunk to the server => writes it to the log =>
|
||||||
|
# tries to send this message to the server => fails to send a chunk and so on.
|
||||||
|
# Writing to a file, which is not exported to the back-end prevents it.
|
||||||
|
# It also allows to increase the fluentd verbosity by default.
|
||||||
|
command:
|
||||||
|
- '/bin/sh'
|
||||||
|
- '-c'
|
||||||
|
- '/run.sh $FLUENTD_ARGS 2>&1 >>/var/log/fluentd.log'
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
memory: 200Mi
|
memory: 200Mi
|
||||||
@ -20,9 +29,6 @@ spec:
|
|||||||
# requests of other per-node add-ons (e.g. kube-proxy).
|
# requests of other per-node add-ons (e.g. kube-proxy).
|
||||||
cpu: 100m
|
cpu: 100m
|
||||||
memory: 200Mi
|
memory: 200Mi
|
||||||
env:
|
|
||||||
- name: FLUENTD_ARGS
|
|
||||||
value: -q
|
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: varlog
|
- name: varlog
|
||||||
mountPath: /var/log
|
mountPath: /var/log
|
||||||
|
Loading…
Reference in New Issue
Block a user