Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Keycloak on kubernetes and logging json layout format with log4j2

I have Keycloak deployed in Kubernetes using the official codecentric chart. Now I want to make Keycloak logs into json format in order to export them to Kibana.

like image 818
REDOUANE Avatar asked Jan 19 '26 12:01

REDOUANE


1 Answers

A comment to the original reply pointed to a cli command to do this.

  cli:
# Custom CLI script
custom: |
  /subsystem=logging/json-formatter=json:add(exception-output-type=formatted, pretty-print=false, meta-data={label=value})
  /subsystem=logging/console-handler=CONSOLE:write-attribute(name=named-formatter, value=json)
like image 148
REDOUANE Avatar answered Jan 21 '26 02:01

REDOUANE



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!