Skip to content

Commit 321f1b8

Browse files
committed
Fix some error about fluentd config file
1.Fix error about source path is not equal to autdit-log-path 2.Fix error about ternary operator of ruby Signed-off-by: pengdake <[email protected]>
1 parent ae9c6fd commit 321f1b8

File tree

1 file changed

+3
-3
lines changed
  • content/en/docs/tasks/debug-application-cluster

1 file changed

+3
-3
lines changed

content/en/docs/tasks/debug-application-cluster/audit.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ In this example, we will use fluentd to split audit events by different namespac
215215
<source>
216216
@type tail
217217
# audit log path of kube-apiserver
218-
path /var/log/audit
218+
path /var/log/kube-audit
219219
pos_file /var/log/audit.pos
220220
format json
221221
time_key time
@@ -225,10 +225,10 @@ In this example, we will use fluentd to split audit events by different namespac
225225
226226
<filter audit>
227227
#https://github.com/fluent/fluent-plugin-rewrite-tag-filter/issues/13
228-
type record_transformer
228+
@type record_transformer
229229
enable_ruby
230230
<record>
231-
namespace ${record["objectRef"].nil? ? "none":(record["objectRef"]["namespace"].nil? ? "none":record["objectRef"]["namespace"])}
231+
namespace ${record["objectRef"].nil?"none":(record["objectRef"]["namespace"].nil?"none":record["objectRef"]["namespace"])}
232232
</record>
233233
</filter>
234234

0 commit comments

Comments
 (0)