Skip to content

Integrate with Prometheus

Permissions

Only users with ROLE_MANAGER permissions can perform these actions.

Prometheus is an open-source monitoring and alerting toolkit that scrapes and stores time series data locally from its configured targets (such as Lightrun) and then runs rules over the data for aggregation, recording, and alerting.

Prometheus offers multiple data visualization and alert configurations modes, including via additional tools such as Grafana, which can be very useful for visualizing Lightrun output data.

Prerequisites

Install and configure Prometheus. Refer to the Prometheus FAQ as well for additional help.

For Lightrun to send observability data to your integrations, ensure:

  • The application has a running agent attached to it
  • Your action Target is set to Plugin.

Enable and disable Prometheus integration

  1. Open a browser and log in to your Lightrun account.

  2. In the menu on the left, click Integrations.

    The page loads with all available integrations:

    Integrations Page -third

  3. From the Integrations page, click Connect from the Prometheus card.

    The Prometheus Integration window pops up:

    Prometheus Configuration -third

  4. Click Copy from under the scrape configuration.

  5. Paste the scrape_configs data to the existing scrape_configs section in your Prometheus YAML configuration file.

    Paste script -third

  6. From the Round Up dropdown list, select the rounding rule to be applied by Prometheus for your Lightrun data.

  7. Click Connect and wait for the approval toast message.

  8. To disable the configuration, click Disconnect.

Confirm your Prometheus integration

If your Prometheus integration was successful:

  1. The Prometheus card Connect button should change to Settings on your Management Portal Integrations page, and Installed should appear on the top left part of the card.

    Prometheus Card -third

  2. Lightrun should appear in your Prometheus interface Targets page, and the connection state should be Up.

    Prometheus Success

Troubleshooting Prometheus integration

  • If the connection state is down, confirm that:

    1. Your firewall rules are not blocking Prometheus queries to the Lightrun server.
    2. There are no communication issues with your Prometheus server.
  • If the connection state is down and there is a server returned HTTP status 403 forbidden error message. This error indicates that Prometheus integration is not currently enabled in your Management Portal.

    Prometheus Fail


Last update: September 20, 2022