From 7d6bd2e6cce754923ca1f8aab125af482e17be6b Mon Sep 17 00:00:00 2001 From: Pierre Rudloff Date: Mon, 18 Jul 2022 23:51:20 +0200 Subject: [PATCH] varnishlog: add page (#8169) --- pages/common/varnishlog.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 pages/common/varnishlog.md diff --git a/pages/common/varnishlog.md b/pages/common/varnishlog.md new file mode 100644 index 000000000..fecdedcb0 --- /dev/null +++ b/pages/common/varnishlog.md @@ -0,0 +1,24 @@ +# varnishlog + +> Display Varnish logs. +> More information: . + +- Display logs in real time: + +`varnishlog` + +- Only display requests to a specific domain: + +`varnishlog -q 'ReqHeader eq "Host: {{example.com}}"'` + +- Only display POST requests: + +`varnishlog -q 'ReqMethod eq "{{POST}}"'` + +- Only display requests to a specific path: + +`varnishlog -q 'ReqURL eq "{{/path}}"'` + +- Only display requests to paths matching a regular expression: + +`varnishlog -q 'ReqURL ~ "{{regex}}"'`