Update Alloy configuration in README to include log level and tail_from_end setting for audit logs
This commit is contained in:
@@ -26,12 +26,15 @@ Add the following configuration to your Alloy setup:
|
||||
```hcl
|
||||
loki.source.file "vault_audit_log" {
|
||||
targets = [
|
||||
{"__path__" = "/var/log/vault/audit.log", "log_name" = "vault_audit"},
|
||||
{"__path__" = "/var/log/vault/audit.log", "log_name" = "vault_audit", "level" = "info"},
|
||||
]
|
||||
forward_to = [loki.write.default.receiver]
|
||||
tail_from_end = true
|
||||
}
|
||||
```
|
||||
|
||||
> **Note:** `tail_from_end = true` ensures that only new log entries are read, preventing the ingestion of old lines/entries. It is (probably) required because the audit log file does not contain timestamps and only entry guids.
|
||||
|
||||
Check auditing configuration with:
|
||||
|
||||
```bash
|
||||
|
||||
Reference in New Issue
Block a user