log as json with haproxy

shared

%(host)[capture.req.hdr(0)] 
%(x_request_id)[capture.req.hdr(1)] 
%(x-real-ip)[capture.req.hdr(2)] 
%(user-agent)[capture.req.hdr(3)] 
%(client_ip)ci 
%(client_port)cp 
%(request_date)tr 
%(status_code)ST 
%(http_request)r 
%(frontend)ft 
%(backend)b 
%(server)s 
%(time_request)TR 
%(time_wait)Tw 
%(time_connect)Tc 
%(time_response)Tr/%(time_active)Ta 
%(bytes_read)B 
%(ssl_sni)[ssl_fc_sni] 
%(ssl_ciphers)sslc 
%(ssl_version)sslv 
%(time_handshake)Th 

dev-only

%(captured_request_cookie)CC 
%(captured_response_cookie)CS 
%(termination_state_cookie)tsc 
%(actconn)ac 
%(feconn)fc 
%(beconn)bc 
%(srv_conn)sc 
%(retries)rc 
%(srv_queue)sq 
%(backend_queue)bq 
%(captured_request_headers)hr 
%(captured_response_headers)hs

HOME | GUIDES | LECTURES | LAB | SMTP HEALTH | HTML5 | CONTACT
Copyright © 2024 Pierre-Philipp Braun