This repository has been archived on 2023-12-13. You can view files and clone it, but cannot push or open issues or pull requests.
2022-05-17 19:13:38 +02:00
|
|
|
data "azurerm_subscription" "current-subscription" {}
|
|
|
|
|
|
|
|
resource "azurerm_consumption_budget_subscription" "subscription-budget" {
|
|
|
|
name = "subscription-budget"
|
2022-05-17 19:14:15 +02:00
|
|
|
subscription_id = data.azurerm_subscription.current-subscription.id
|
2022-05-17 19:13:38 +02:00
|
|
|
|
|
|
|
amount = 5
|
|
|
|
time_grain = "Monthly"
|
|
|
|
|
2022-05-17 19:19:01 +02:00
|
|
|
time_period {
|
|
|
|
start_date = "2022-05-01T00:00:00Z"
|
|
|
|
}
|
2022-05-17 19:13:38 +02:00
|
|
|
|
|
|
|
notification {
|
2022-05-17 19:16:11 +02:00
|
|
|
enabled = true
|
2022-05-17 19:13:38 +02:00
|
|
|
threshold = 85.0
|
|
|
|
operator = "GreaterThan"
|
|
|
|
threshold_type = "Forecasted"
|
|
|
|
|
|
|
|
contact_roles = [
|
|
|
|
"Owner",
|
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|