google_logging_folder_exclusion

Manages a folder-level logging exclusion. For more information see:

Example Usage

resource "google_logging_folder_exclusion" "my-exclusion" {
  name   = "my-instance-debug-exclusion"
  folder = google_folder.my-folder.name

  description = "Exclude GCE instance debug logs"

  # Exclude all DEBUG or lower severity messages relating to instances
  filter = "resource.type = gce_instance AND severity <= DEBUG"
}

resource "google_folder" "my-folder" {
  display_name = "My folder"
  parent       = "organizations/123456"
}

Argument Reference

The following arguments are supported:

Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

Import

Folder-level logging exclusions can be imported using their URI, e.g.

In Terraform v1.5.0 and later, use an import block to import folder-level logging exclusions using one of the formats above. For example:

import {
  id = "folders/{{folder}}/exclusions/{{name}}"
  to = google_logging_folder_exclusion.default
}

When using the terraform import command, folder-level logging exclusions can be imported using one of the formats above. For example:

$ terraform import google_logging_folder_exclusion.default folders/{{folder}}/exclusions/{{name}}