Skip to content

Commit

Permalink
Merge pull request #4624 from sgibson91/tf-azure/fix-budget-alerts
Browse files Browse the repository at this point in the history
Update budget alert config for Azure terraform for a clean apply
  • Loading branch information
sgibson91 authored Aug 15, 2024
2 parents 8d98f5b + cc0d54a commit 69c61b8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 3 additions & 1 deletion terraform/azure/budget-alerts.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
data "azurerm_subscription" "current" {}
resource "azurerm_consumption_budget_subscription" "budget" {
count = var.budget_alert_enabled ? 1 : 0

name = "BudgetSubscription-${var.resourcegroup_name}"
subscription_id = data.azurerm_subscription.current.id

Expand All @@ -12,7 +14,7 @@ resource "azurerm_consumption_budget_subscription" "budget" {
}

notification {
enabled = var.budget_alert_enabled ? true : false
enabled = true
threshold = 120
operator = "GreaterThanOrEqualTo"
threshold_type = "Forecasted"
Expand Down
7 changes: 3 additions & 4 deletions terraform/azure/projects/utoronto.tfvars
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,13 @@ resourcegroup_name = "2i2c-utoronto-cluster"
global_container_registry_name = "2i2cutorontohubregistry"
global_storage_account_name = "2i2cutorontohubstorage"
location = "canadacentral"

storage_size = 10240
ssh_pub_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDQJ4h39UYNi1wybxAH+jCFkNK2aqRcuhDkQSMx0Hak5xkbt3KnT3cOwAgUP1Vt/SjhltSTuxpOHxiAKCRnjwRk60SxKhUNzPHih2nkfYTmBBjmLfdepDPSke/E0VWvTDIEXz/L8vW8aI0QGPXnXyqzEDO9+U1buheBlxB0diFAD3vEp2SqBOw+z7UgrGxXPdP+2b3AV+X6sOtd6uSzpV8Qvdh+QAkd4r7h9JrkFvkrUzNFAGMjlTb0Lz7qAlo4ynjEwzVN2I1i7cVDKgsGz9ZG/8yZfXXx+INr9jYtYogNZ63ajKR/dfjNPovydhuz5zQvQyxpokJNsTqt1CiWEUNj georgiana@georgiana"
budget_alert_amount = null
storage_size = 10240
ssh_pub_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDQJ4h39UYNi1wybxAH+jCFkNK2aqRcuhDkQSMx0Hak5xkbt3KnT3cOwAgUP1Vt/SjhltSTuxpOHxiAKCRnjwRk60SxKhUNzPHih2nkfYTmBBjmLfdepDPSke/E0VWvTDIEXz/L8vW8aI0QGPXnXyqzEDO9+U1buheBlxB0diFAD3vEp2SqBOw+z7UgrGxXPdP+2b3AV+X6sOtd6uSzpV8Qvdh+QAkd4r7h9JrkFvkrUzNFAGMjlTb0Lz7qAlo4ynjEwzVN2I1i7cVDKgsGz9ZG/8yZfXXx+INr9jYtYogNZ63ajKR/dfjNPovydhuz5zQvQyxpokJNsTqt1CiWEUNj georgiana@georgiana"

# List available versions via: az aks get-versions --location westus2 -o table
kubernetes_version = "1.28.3"


# Ref https://github.com/2i2c-org/meta/issues/539
kubernetes_rbac_enabled = false

Expand Down

0 comments on commit 69c61b8

Please sign in to comment.