google_iam_workload_identity_pool

Represents a collection of external workload identities. You can define IAM policies to grant these identities access to Google Cloud resources.

To get more information about WorkloadIdentityPool, see:

Open in Cloud Shell

Example Usage - Iam Workload Identity Pool Basic

resource "google_iam_workload_identity_pool" "example" {
  workload_identity_pool_id = "example-pool"
}
Open in Cloud Shell

Example Usage - Iam Workload Identity Pool Full

resource "google_iam_workload_identity_pool" "example" {
  workload_identity_pool_id = "example-pool"
  display_name              = "Name of pool"
  description               = "Identity pool for automated test"
  disabled                  = true
}

Argument Reference

The following arguments are supported:


Attributes Reference

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

Timeouts

This resource provides the following Timeouts configuration options:

Import

WorkloadIdentityPool can be imported using any of these accepted formats:

In Terraform v1.5.0 and later, use an import block to import WorkloadIdentityPool using one of the formats above. For example:

import {
  id = "projects/{{project}}/locations/global/workloadIdentityPools/{{workload_identity_pool_id}}"
  to = google_iam_workload_identity_pool.default
}

When using the terraform import command, WorkloadIdentityPool can be imported using one of the formats above. For example:

$ terraform import google_iam_workload_identity_pool.default projects/{{project}}/locations/global/workloadIdentityPools/{{workload_identity_pool_id}}
$ terraform import google_iam_workload_identity_pool.default {{project}}/{{workload_identity_pool_id}}
$ terraform import google_iam_workload_identity_pool.default {{workload_identity_pool_id}}

User Project Overrides

This resource supports User Project Overrides.