Skip to content

Commit

Permalink
feat(google_gke_namespace_logging): create a bigquery linked dataset …
Browse files Browse the repository at this point in the history
…to namespace logging bucket (#182)
  • Loading branch information
jasonthomas authored May 20, 2024
1 parent 31e6916 commit 09bc2aa
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion google_gke_namespace_logging/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,11 @@ resource "google_bigquery_dataset_iam_member" "logging_dataset_writer" {
dataset_id = google_bigquery_dataset.namespace[0].dataset_id
role = "roles/bigquery.dataEditor"
member = var.logging_writer_service_account_member
}
}

resource "google_logging_linked_dataset" "namespace_linked_dataset" {
count = var.log_analytics ? 1 : 0
link_id = replace("gke-${local.tenant_namespace}-log-linked", "-", "_")
bucket = google_logging_project_bucket_config.namespace[0].id
description = "Linked Dataset for GKE Namespace Logging ${local.tenant_namespace}"
}

0 comments on commit 09bc2aa

Please sign in to comment.