Closed awebc closed 4 years ago
From the README:
# default Nginx format:
$parser->setFormat('%h %l %u %t "%r" %>s %O "%{Referer}i" \"%{User-Agent}i"');
You can customize the format as you wish, but using Nginx's log_format
way of writing is not supported. You should be able to find alternatives for most of the options.
The format is based on Apache's: https://httpd.apache.org/docs/2.4/en/mod/mod_log_config.html#formats
Ah, my bad, I read that too fast.
As noted in #21 and #34, parsing the error.log
is not the goal of this project.
Given how structured it can become (specially when PHP errors are piped to this file), you'll have to write a custom stream just to get each log entry, given they can be multiline.
How to set nginx error.log format ?