Logging in JSON format

This commit is contained in:
Paramtamtam
2021-05-03 20:57:35 +05:00
parent 19c9d5528e
commit 009ec66d86
3 changed files with 9 additions and 2 deletions

View File

@@ -17,7 +17,8 @@ nscache 65536
timeouts 1 5 30 60 180 1800 15 60
log /dev/stdout
logformat "- +_L%t.%. %N.%p %E %U %C:%c %R:%r %O %I %h %T"
# Logging docs: <https://3proxy.org/doc/howtor.html#LOGFORMAT>
logformat "-\""+_G{""time_unix"":%t, ""proxy"":{""type:"":""%N"", ""port"":%p}, ""error"":{""code"":""%E""}, ""user"":""%U"", ""client"":{""ip"":""%C"", ""port"":%c}, ""server"":{""ip"":""%R"", ""port"":%r}, ""bytes"":{""sent"":%O, ""received"":%I}, ""hostname"":""%n"", ""message"":""%T""}"
maxconn 1024