ClusterSecret icon indicating copy to clipboard operation
ClusterSecret copied to clipboard

Make logs configurable via environment variables

Open Anton0C opened this issue 1 year ago • 1 comments

Description:

It would be useful to make the logging behavior of the application configurable. Specifically, I would like to:

  1. Change the verbosity of logs (e.g., INFO, DEBUG, ERROR).
  2. Enable or disable JSON output for logs.
  3. Pass custom log format strings.

All of these configurations should be adjustable via environment variables to provide more flexibility in different environments.

Suggested environment variables:

  • LOG_LEVEL: Set the logging verbosity level (e.g., INFO, DEBUG, ERROR).
  • LOG_ENCODER: Enable plain text or JSON logging output (plain or json).
  • LOG_FORMAT: Ability to customize the content of each log string.

Anton0C avatar Sep 10 '24 09:09 Anton0C

@zakkg3 Could you take a look ? Thanks!

Anton0C avatar Sep 13 '24 08:09 Anton0C