Last active
November 18, 2021 22:12
-
-
Save raucao/5653620 to your computer and use it in GitHub Desktop.
Nginx log format for detailed JSON entries
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
log_format json '{"ip":"$remote_addr",' | |
'"time":"$time_local",' | |
'"host":"$host",' | |
'"method":"$request_method",' | |
'"uri":"$uri",' | |
'"status":$status,' | |
'"size":$body_bytes_sent,' | |
'"referer":"$http_referer",' | |
'"ua":"$http_user_agent"}'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment