Merge remote-tracking branch 'origin/master' into fast-dev

This commit is contained in:
Ludovico Magnocavallo
2026-02-10 15:59:57 +00:00
16 changed files with 434 additions and 30 deletions

View File

@@ -135,7 +135,7 @@ resource "google_monitoring_alert_policy" "alerts" {
# first try to get a channel created by this module
google_monitoring_notification_channel.channels[x].name,
# otherwise check the context
var.context.notification_channels[x],
local.ctx.notification_channels[x],
# if nothing else, use the provided channel as is
x
)

View File

@@ -1,5 +1,5 @@
/**
* Copyright 2025 Google LLC
* Copyright 2026 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -71,7 +71,7 @@ resource "google_logging_metric" "metrics" {
disabled = each.value.disabled
bucket_name = try(
# first try to check the context
var.context.log_buckets[each.value.bucket_name],
local.ctx.log_buckets[each.value.bucket_name],
# if nothing else, use the provided channel as is
each.value.bucket_name
)

View File

@@ -1,5 +1,5 @@
/**
* Copyright 2025 Google LLC
* Copyright 2026 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -45,8 +45,16 @@ resource "google_monitoring_notification_channel" "channels" {
description = each.value.description
display_name = each.value.display_name
enabled = each.value.enabled
labels = each.value.labels
user_labels = each.value.user_labels
labels = each.value.labels == null ? null : {
for k, v in each.value.labels :
# allow interpolation of email addresses and pubsub topics
k => try(
local.ctx.email_addresses[v],
local.ctx.pubsub_topics[v],
v
)
}
user_labels = each.value.user_labels
dynamic "sensitive_labels" {
for_each = each.value.sensitive_labels[*]
content {