-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Caddy iso8601 #2780
Comments
I think '%Y-%m-%dT%H:%M:%S.%f%z' should be able to match '2025-01-05T23:01:44.850+0800'? |
This is going to be tricky without preprocessing, since I don't think
|
I completed the parsing using the following command: sd '"ts":"(.{19}).{4}(.+?)"' '"ts":"$1$2"' <./logs/$remote_host/$site_name.jsonl \
| goaccess - \
-o ./logs/$remote_host/$site_name.html \
-j 6 \
--datetime-format '%FT%T%z' \
--log-format '{"ts":"%x","request":{"client_ip":"%h","proto":"%H","method":"%m","host":"%v","uri":"%U","headers":{"User-Agent":["%u"],"Referer":["%R"]},"tls":{"cipher_suite":"%k","proto": "%K"}},"duration": "%T","size": "%b","status": "%s","resp_headers":{"Content-Type":["%M"]}}' |
You might consider adding it to the usage examples of goaccess, as it is a solution. |
Awesome, thanks for sharing that solution! |
You're welcome. |
I'm using the following command to parse Caddy logs:
An error occurred:
One of my Caddy log lines is:
The text was updated successfully, but these errors were encountered: