Skip to content

Promtail notes

Published: at 12:00 AMSuggest Changes
server:
  http_listen_port: 9080
  grpc_listen_port: 0

positions:
  filename: /tmp/positions.yaml

clients:
  - url: http://x.x.x.x:3100/loki/api/v1/push

scrape_configs:
- job_name: backend-A
  static_configs:
  - targets:
      - localhost
    labels:
      hostname: backend-A
      job: containers
      __path__: /opt/backend-A/logs/access.log
- job_name: backend-B
  static_configs:
  - targets:
      - localhost
    labels:
      hostname: backend-B
      job: containers
      __path__: /opt/backend-B/logs/access.log

Previous Post
How to install node exporter in linux
Next Post
Tools debug in k8s