Loki-k8s docs - integration

Integrating Loki

Loki integrates with the following:

  1. Any charm that supports the loki_push_api interface. You can integrate it using the Loki Charm library. The documentation of the charm library, available through Charmhub provides further details. The information exchanged through the loki_push interface can be broken down into two parts
  • Loki charm provides an endpoint URL to receive log from Loki clients that relates with this charm.

  • Loki may receive alert rules which tell when to raise alerts. These rules are read from a directory named loki_alert_rules, if present at the top level, within the client charm’s source (src) directory.

Any time new relations are made, or existing ones changed, between the Loki charm and any scrape target charm, a new Loki configuration is generated.

  1. Loki integrates with Grafana which provides a dashboard for viewing logs aggregated by Loki. These dasboards may be customised by charms that relate to Grafana.

  2. Loki forwards alerts to one or more Alertmanagers that are related to it.