OIDC IdP configuration for a Identity Toolkit project within a tenant.
You must enable the Google Identity Platform in the marketplace prior to using this resource.
resource "google_identity_platform_tenant" "tenant" {
display_name = "tenant"
}
resource "google_identity_platform_tenant_oauth_idp_config" "tenant_oauth_idp_config" {
name = "oidc.oauth-idp-config"
tenant = google_identity_platform_tenant.tenant.name
display_name = "Display Name"
client_id = "client-id"
issuer = "issuer"
enabled = true
client_secret = "secret"
}
The following arguments are supported:
name
-
(Required)
The name of the OauthIdpConfig. Must start with oidc.
.
tenant
-
(Required)
The name of the tenant where this OIDC IDP configuration resource exists
display_name
-
(Required)
Human friendly display name.
issuer
-
(Required)
For OIDC Idps, the issuer identifier.
client_id
-
(Required)
The client id of an OAuth client.
enabled
-
(Optional)
If this config allows users to sign in with the provider.
client_secret
-
(Optional)
The client secret of the OAuth client, to enable OIDC code flow.
project
- (Optional) The ID of the project in which the resource belongs.
If it is not provided, the provider project is used.
In addition to the arguments listed above, the following computed attributes are exported:
id
- an identifier for the resource with format projects/{{project}}/tenants/{{tenant}}/oauthIdpConfigs/{{name}}
This resource provides the following Timeouts configuration options:
create
- Default is 20 minutes.update
- Default is 20 minutes.delete
- Default is 20 minutes.TenantOauthIdpConfig can be imported using any of these accepted formats:
projects/{{project}}/tenants/{{tenant}}/oauthIdpConfigs/{{name}}
{{project}}/{{tenant}}/{{name}}
{{tenant}}/{{name}}
In Terraform v1.5.0 and later, use an import
block to import TenantOauthIdpConfig using one of the formats above. For example:
import {
id = "projects/{{project}}/tenants/{{tenant}}/oauthIdpConfigs/{{name}}"
to = google_identity_platform_tenant_oauth_idp_config.default
}
When using the terraform import
command, TenantOauthIdpConfig can be imported using one of the formats above. For example:
$ terraform import google_identity_platform_tenant_oauth_idp_config.default projects/{{project}}/tenants/{{tenant}}/oauthIdpConfigs/{{name}}
$ terraform import google_identity_platform_tenant_oauth_idp_config.default {{project}}/{{tenant}}/{{name}}
$ terraform import google_identity_platform_tenant_oauth_idp_config.default {{tenant}}/{{name}}
This resource supports User Project Overrides.