Skip to main content

Infrastructure as code

Coralogix supports Service Level Objectives (SLOs) through multiple deployment and management options. Depending on your environment, you can choose automated provisioning through the Coralogix Terraform provider or Kubernetes-native automation via the Coralogix Operator (coming soon).

Note

To create SLO alerts via Terraform, Alerts API v3 is required. To migrate from Alerts API v2 to v3, follow this guide.

Terraform provider​

The Coralogix Terraform provider allows you to define and manage SLOs as code, ensuring consistent provisioning across environments. Learn more about using the Coralogix Terraform provider to create and manage SLOs in the Coralogix Terraform Provider documentation.

Note

You cannot create an SLO on an empty dataset. Ensure that the metric on which your SLO is based is actively reporting data to Coralogix before attempting to create the SLO. In practice, this means the metric chosen for an SLO must already be sending data to Coralogix.

SLOs​

Set up SLOs here. Run terraform init -upgrade to make sure your setup uses the latest version of the Terraform Provider.

Calendar-month window

In addition to the rolling 1-, 7-, 14-, 21-, 28-, and 30-day windows, the SLO API accepts a calendar-month window: set sloTimeFrame to SLO_TIME_FRAME_CALENDAR_MONTH. The SLO is evaluated over the current calendar month in UTC, from the start of the month up to the time of evaluation. In the SLO Center, the same window is the current calendar month option.

SLO burn rate alerts​

Create SLO burn rate alerts here using resource "coralogix_alert" "slo_alert_burn_rate".

SLO error budget alerts​

Create SLO error budget alerts here using resource "coralogix_alert" "slo_alert_error_budget".

Last updated on