allinurl / goaccess

GoAccess is a real-time web log analyzer and interactive viewer that runs in a terminal in *nix systems or through your browser.
https://goaccess.io
MIT License
18.38k stars 1.11k forks source link

NPM Log Format #2285

Closed r4tze closed 2 years ago

r4tze commented 2 years ago

I was a little disappointed when I realized the nginx proxy manager (https://nginxproxymanager.com/) does not use a standard nginx logging format. I tried a few alternations but now I‘m stuck with:

Token 'https' doesn't match specifier '%H'

This is my log format: log_format [%d:%t %^] - %s %^ - %m %H %v "%U" [Client %h] [Length %b] [Gzip %^] [Send-to ~h] "%u" "%R"

And this is the log line: [03/Mar/2022:20:07:48 +0000] - 200 200 - POST https domain.de "/folder/stuff/git-receive-pack" [Client 12.34.56.78] [Length 0] [Gzip -] [Sent-to 98.76.54.32] "AppleWebKit" "-"

What am I missing?

allinurl commented 2 years ago

Please try:

goaccess access.log --log-format='[%d:%t %^] - %s %^ - %m %^ %v "%U" [Client %h] [Length %b] %^"%u" "%R"' --date-format=%d/%b/%Y --time-format=%T
r4tze commented 2 years ago

This works like a charm! Thank you!