FEAT(loki): add journald scraping to promtail

This commit is contained in:
Sebastian Mark 2022-03-30 10:52:30 +02:00
parent f28eeb3fda
commit 669a27fff5

View file

@ -3,3 +3,28 @@ loki:
chart: grafana/loki-stack chart: grafana/loki-stack
url: https://grafana.github.io/helm-charts url: https://grafana.github.io/helm-charts
namespace: metrics namespace: metrics
vals:
promtail:
extraScrapeConfigs:
- job_name: journal
journal:
path: /var/log/journal
max_age: 12h
labels:
job: systemd-journal
relabel_configs:
- source_labels:
- '__journal__systemd_unit'
target_label: 'unit'
- source_labels:
- '__journal__hostname'
target_label: 'hostname'
extraVolumes:
- name: journal
hostPath:
path: /var/log/journal
extraVolumeMounts:
- name: journal
mountPath: /var/log/journal
readOnly: true