diff options
author | 2023-08-21 20:07:55 +0200 | |
---|---|---|
committer | 2023-08-21 19:07:55 +0100 | |
commit | 4ae16bce8c6aa8e3d96ca69015d2065badee3994 (patch) | |
tree | ebced804b50c4905e133d606b6416e0fce7b9f72 /test/envparsing.sh | |
parent | [performance] Tweak media attachment cleanup; replace stale index (#2143) (diff) | |
download | gotosocial-4ae16bce8c6aa8e3d96ca69015d2065badee3994.tar.xz |
[feature] Make log format configurable (#2130)
* [feature] Don't emit timestamp in log lines
When running gotosocial with a service manager like systemd, or a
container runtime, the associated log driver usually emits timestamps
itself. In those cases, having the extra timestamp from our own log
lines ends up being a bit noisy and when centrally ingesting logs is
duplicate information.
This introduces a configuration flag that allows disabling emitting the
timestamp. It's only wired up for "daemonised" processes, meaning server
and testrig.
* [chore] Add docs for log-timestamp
* [feature] Simplify timestamp handling
Co-Authored-By: kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com>
* [chore] Less escaped double-quotes
* [chore] Fix help string
---------
Co-authored-by: kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com>
Diffstat (limited to 'test/envparsing.sh')
-rwxr-xr-x | test/envparsing.sh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/envparsing.sh b/test/envparsing.sh index 0cad04416..2ab17dbfb 100755 --- a/test/envparsing.sh +++ b/test/envparsing.sh @@ -86,6 +86,7 @@ EXPECT=$(cat << "EOF" "log-client-ip": false, "log-db-queries": true, "log-level": "info", + "log-timestamp-format": "banana", "media-description-max-chars": 5000, "media-description-min-chars": 69, "media-emoji-local-max-size": 420, @@ -155,6 +156,7 @@ EOF # Set all the environment variables to # ensure that these are parsed without panic OUTPUT=$(GTS_LOG_LEVEL='info' \ +GTS_LOG_TIMESTAMP_FORMAT="banana" \ GTS_LOG_DB_QUERIES=true \ GTS_LOG_CLIENT_IP=false \ GTS_APPLICATION_NAME=gts \ |