-
-
Save ssh60/622098b7f7dcbb15bc71e462aef769a7 to your computer and use it in GitHub Desktop.
Logstash log_format for Nginx
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 logstash_json '{ "@timestamp": "$time_iso8601", ' | |
| '"@version": "1", ' | |
| '"remote_addr": "$remote_addr", ' | |
| '"body_bytes_sent": "$body_bytes_sent", ' | |
| '"request_time": "$request_time", ' | |
| '"upstream_addr": "$upstream_addr", ' | |
| '"upstream_status": "$upstream_status", ' | |
| '"upstream_response_time": "$upstream_response_time", ' | |
| '"status": "$status", ' | |
| '"uri": "$uri", ' | |
| '"query_strings": "$query_string", ' | |
| '"request_method": "$request_method", ' | |
| '"http_referrer": "$http_referer", ' | |
| '"http_host": "$http_host", ' | |
| '"scheme": "$scheme", ' | |
| '"http_user_agent": "$http_user_agent" }'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment