forked from UKHomeOffice/docker-nginx-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlogging.conf
More file actions
34 lines (33 loc) · 1.33 KB
/
Copy pathlogging.conf
File metadata and controls
34 lines (33 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Text format extended logging
log_format extended_text '$real_client_ip_if_set$remote_addr - $remote_user [$time_local] '
'"$request"$uuid_log_opt $status $bytes_sent '
'"$http_referer" "$http_user_agent" "$gzip_ratio" '
'$ssl_client_verify '
'"$ssl_client_s_dn" ';
# JSON formatted extended logging. (Nginx escapes quotes so should be safe http://serverfault.com/a/584887)..."
log_format extended_json '{'
'"proxy_proto_address": "$proxy_protocol_addr", '
'"remote_addr": "$remote_addr", '
'"country_code": "$country_code", '
'"http_host": "$host", '
'"remote_user": "$remote_user", '
'"timestamp": "$time_iso8601", '
'"nginx_uuid": "$uuid", '
'"request_uri": "$request_uri", '
'"request_method": "$request_method", '
'"request_body": "$request_body", '
'"response_body": "$response_body", '
'"http_status": "$status", '
'"body_bytes_sent": "$body_bytes_sent", '
'"http_referer": "$http_referer", '
'"http_user_agent": "$http_user_agent", '
'"http_x_forwarded_for": "$http_x_forwarded_for", '
'"request_time": "$request_time", '
'"upstream_response_time": "$upstream_response_time", '
'"upstream_addr": "$upstream_addr", '
'"upstream_status": "$upstream_status", '
'"scheme": "$scheme", '
'"gzip_ratio": "$gzip_ratio", '
'"ssl_client_verify": "$ssl_client_verify", '
'"ssl_client_s_dn": "$ssl_client_s_dn" '
'}';