xpeditis2.0/infra/logging/promtail/promtail-config.yml
David 40d917e160
All checks were successful
CD Preprod / Backend — Lint (push) Successful in 10m22s
CD Preprod / Frontend — Lint & Type-check (push) Successful in 10m55s
CD Preprod / Backend — Unit Tests (push) Successful in 10m10s
CD Preprod / Frontend — Unit Tests (push) Successful in 10m34s
CD Preprod / Backend — Integration Tests (push) Successful in 9m57s
CD Preprod / Build Frontend (push) Successful in 47s
CD Preprod / Build Log Exporter (push) Successful in 33s
CD Preprod / Build Backend (push) Successful in 7m24s
CD Preprod / Deploy to Preprod (push) Successful in 24s
CD Preprod / Notify Failure (push) Has been skipped
CD Preprod / Notify Success (push) Successful in 2s
chore(ci): remove smoke tests from preprod and prod pipelines
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-06 20:13:17 +02:00

59 lines
1.5 KiB
YAML

server:
http_listen_port: 9080
log_level: warn
positions:
filename: /tmp/positions.yaml
clients:
- url: http://xpeditis-loki:3100/loki/api/v1/push
batchwait: 1s
batchsize: 1048576
timeout: 10s
scrape_configs:
- job_name: docker
docker_sd_configs:
- host: unix:///var/run/docker.sock
refresh_interval: 5s
filters:
- name: label
values: ['logging=promtail']
relabel_configs:
- source_labels: ['__meta_docker_container_label_logging_service']
target_label: service
- source_labels: ['__meta_docker_container_name']
regex: '/?(.*)'
replacement: '${1}'
target_label: container
- source_labels: ['__meta_docker_container_log_stream']
target_label: stream
pipeline_stages:
- drop:
older_than: 15m
drop_counter_reason: entry_too_old
- drop:
expression: 'GET /(health|metrics|minio/health)'
- json:
expressions:
level: level
msg: msg
context: context
reqId: reqId
- labels:
level:
context:
- template:
source: level
template: >-
{{ if eq .Value "10" }}trace{{ else if eq .Value "20" }}debug{{ else if eq .Value "30" }}info{{ else if eq .Value "40" }}warn{{ else if eq .Value "50" }}error{{ else if eq .Value "60" }}fatal{{ else }}{{ .Value }}{{ end }}
- labels:
level: