Skip to content

Commit bd6225f

Browse files
committed
rewrite_tag plugin hostname command fix to work with OL8 Image on OCR
1 parent 1da38c7 commit bd6225f

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

logan/helm-chart/templates/configmap-logs.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ data:
262262
# Match block to filter kubelet logs from syslogs
263263
<match oci.oke.syslog.messages.**>
264264
@type rewrite_tag_filter
265+
hostname_command {{ ((.Values.fluentd).rewriteTagPlugin).hostname_command | default "cat /etc/hostname" }}
265266
<rule>
266267
key message
267268
pattern /kubelet:/

logan/helm-chart/values.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,11 @@ fluentd:
153153
# Specifies the encoding of logs. By default, in_tail emits string value as ASCII-8BIT encoding. If encoding is specified, in_tail changes string to given encoding.
154154
# When encoding is set at this level, it gets applied to all the logs being collected. Instead, it can also be set at individual logs under sections like kubernetesSystem, genericContainerLogs, customLogs etc.
155155
# encoding:
156+
157+
# Configuration for rewrite_tag plugin
158+
rewriteTagPlugin:
159+
hostname_command: "cat /etc/hostname"
160+
156161
# Configuration for Kubernetes System specific logs like Kube Flannel, Kube Proxy etc.
157162
kubernetesSystem:
158163
# Setting the following properties will override the default/generic configuration and applies to all Kubernetes system logs

0 commit comments

Comments
 (0)