Skip to content

Commit

Permalink
Update README to include how to set up env var for production style logs
Browse files Browse the repository at this point in the history
  • Loading branch information
lauraghiorghisor-tw committed Jul 4, 2023
1 parent b3edf9d commit 5565808
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,13 @@ check docs](docs/healthchecks.md) for more information on how to use it.
In Rails applications, the application will be configured to send JSON-formatted
logs to `STDOUT` and unstructured logs to `STDERR`.

To enable production-like logging, an env variable `GOVUK_RAILS_JSON_LOGGING`
is set in the `govuk-helm-charts` and then checked in `railtie.rb`. This will
allow JSON format logs and `Govuk-Request-Id` to be visible.

For development logs, in order to see the production style logs, developers should
set `GOVUK_RAILS_JSON_LOGGING`in `govuk-docker` -> `docker-compose` files.


## Content Security Policy generation

Expand Down

0 comments on commit 5565808

Please sign in to comment.