Skip to main content

Create an SLO

Create and manage SLOs with Terraform​

Reading time: 0 minute(s) (0 words)
See how to configure your SLO with the Nobl9 Terraform provider.

With data sources connected via Terraform, you can now manage and create your SLOs. Here’s an example of a Nobl9 SLO created via Terraform:


resource "nobl9_slo" "web-slo" {
name = "web-slo"
service = "web-service"
budgeting_method = "Occurrences"
project = "web-project"

label {
key = "team"
values = ["engineering"]
}

time_window {
unit = "Day"
count = 14
is_rolling = true
}

objective {
target = 0.999
value = 5
display_name = "Good"
op = "lte"

raw_metric {
query {
prometheus {
promql = "server_requestMsec{host=\"*\",instance=\"143.146.168.125:9913\",job=\"nginx\"}"
}
}
}
}

indicator {
name = "web-prometheus"
kind = "Agent"
project = "web-project"
}
}

For more information on how to configure Nobl9 SLOs via the Nobl9 Terraform provider, make sure to check the nobl9_slo article.

Great, you can now create and manage SLOs with the Nobl9 Terraform provider!