Commit 4340ddaf authored by Michał Woźniak's avatar Michał Woźniak

README improvements

parent 088ce501
# Watchful Matomo Log Analytics (for Matomo 3.x)
Matomo's [log analytics](https://matomo.org/log-analytics/), automatically watching specified directories for logs to ingest. Any detected logfiles are ingested and moved out of the way or deleted.
Matomo's [log analytics](https://matomo.org/log-analytics/), but automatically watching specified directories for logs to ingest. Any detected logfiles are ingested and moved out of the way or deleted.
The script should be useful in situations where webserver logfiles are to be ingested into Matomo upon log rotation, without the need to set up elaborate systems of cronjobs.
## Requirements
......@@ -22,20 +24,20 @@ While ingestion is in progress new files are *not* being added to the batch. Onc
Run `./logwatch.py --help` to get help. All `import_logs.py` options are supported, plus these additional ones:
- `--logfiles-glob` (default: `"*.log"`)
- `--logfiles-glob` (default: `"*.log"`)
Only files matching this shell glob expression will be ingested. It's
important to make sure that the glob does not match ingested files after
prefix and suffix is applied! See `--prefix-ingested` and `--suffix-ingested`.
- `--ingestion-grace-period` (default: `5`)
- `--ingestion-grace-period` (default: `5`)
Delay (in seconds; fractions are supported) between noticing a logfile to be processed and starting ingesting it.
This is part of the built-in heuristic for determining that a file is not being modified
or moved anymore and can be safely ingested.
- `--delete-ingested` (default: False)
- `--delete-ingested` (default: False)
Delete successfully ingested logfiles.
- `--prefix-ingested` (default: `"ingested/"`)
- `--prefix-ingested` (default: `"ingested/"`)
Rename ingested logfiles using this prefix; prefix can indicate directories (in
which case it should contain '/'), and is then relative to the directory a given
logfile was originally in: when watching several directories, a prefix of
......@@ -43,18 +45,18 @@ Run `./logwatch.py --help` to get help. All `import_logs.py` options are support
respective watched directories. Directories will be created if needed. This option
is ignored if `--delete-ingested` is used.
- `--suffix-ingested` (default: `".ingested"`)
- `--suffix-ingested` (default: `".ingested"`)
Rename ingested logfiles using this suffix; it cannot contain any '/' characters.
This option is ignored if `--delete-ingested` is used.
- `--exit-on-error` (default: False)
- `--exit-on-error` (default: False)
Exit when ingestion errors are encountered.
- `--delete-failed` (default: False)
- `--delete-failed` (default: False)
Delete logfiles which failed to be ingested.
- `--prefix-failed` (default: `"failed/"`)
- `--prefix-failed` (default: `"failed/"`)
Rename logfiles that failed to be ingested using this prefix; prefix can
have directories (in which case it should contain '/'), and is then relative
to the directory a given logfile was originally in: when watching several
......@@ -65,11 +67,11 @@ Run `./logwatch.py --help` to get help. All `import_logs.py` options are support
This option is ignored if `--delete-failed` is used.
- `--suffix-failed` (default: `".failed"`)
- `--suffix-failed` (default: `".failed"`)
Rename logfiles that failed to be ingested using this suffix; it cannot
contain any '/' characters. This option is ignored if `--delete-failed` is used.
- `--no-auto-archive` (default: True)
- `--no-auto-archive` (default: True)
Do not automatically run auto-archiving of Matomo reports. By default
auto-archiving is triggered after a batch of logfiles is ingested
......@@ -80,7 +82,6 @@ Run the image with log directories you want to watch volume-mounted. Specify the
### Example docker-compose service
```yaml
# loading nginx logfiles into matomo
logwatch:
build: https://git.rys.io/libre/watchful-matomo-log-analytics.git
volumes:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment