Google Cloud Identity Group Membership

This page shows how to write Terraform for Cloud Identity Group Membership and write them securely.

google_cloud_identity_group_membership (Terraform)

The Group Membership in Cloud Identity can be configured in Terraform with the resource name google_cloud_identity_group_membership. The following sections describe 5 examples of how to use the resource and its parameters.

Example Usage from GitHub

github-iconapsureda/ci-groups
resource "google_cloud_identity_group_membership" "obe-bu2-cigroups-app3_leslie_lamport_apszaz_com" {
  group = google_cloud_identity_group.obe-bu2-cigroups-app3.id
  preferred_member_key {
    id = "leslie.lamport@apszaz.com"
  }
  roles {
github-iconapsureda/ci-groups
resource "google_cloud_identity_group_membership" "obe-bu1-cigroups-app1_leslie_lamport_apszaz_com" {
  group = google_cloud_identity_group.obe-bu1-cigroups-app1.id
  preferred_member_key {
    id = "leslie.lamport@apszaz.com"
  }
  roles {
github-iconapsureda/gci-groups
resource "google_cloud_identity_group_membership" "tnt1-bu1-cigroups-app3_leslie_lamport_apszaz_com" {
  group = google_cloud_identity_group.tnt1-bu1-cigroups-app3.id
  preferred_member_key {
    id = "leslie.lamport@apszaz.com"
  }
  roles {
github-iconapsureda/ci-groups
resource "google_cloud_identity_group_membership" "obe-bu2-cigroups-app1_leslie_lamport_apszaz_com" {
  group = google_cloud_identity_group.obe-bu2-cigroups-app1.id
  preferred_member_key {
    id = "leslie.lamport@apszaz.com"
  }
  roles {
github-iconapsureda/gci-groups
resource "google_cloud_identity_group_membership" "tnt1-bu1-cigroups-app1_leslie_lamport_apszaz_com" {
  group = google_cloud_identity_group.tnt1-bu1-cigroups-app1.id
  preferred_member_key {
    id = "leslie.lamport@apszaz.com"
  }
  roles {

Parameters

  • create_time requiredcomputed - string
    • The time when the Membership was created.

  • group required - string
    • The name of the Group to create this membership in.

  • id optionalcomputed - string
  • name requiredcomputed - string
    • The resource name of the Membership, of the form groups/{group_id}/memberships/{membership_id}.

  • type requiredcomputed - string
    • The type of the membership.

  • update_time requiredcomputed - string
    • The time when the Membership was last updated.

Explanation in Terraform Registry

A Membership defines a relationship between a Group and an entity belonging to that Group, referred to as a "member". To get more information about GroupMembership, see:

  • API documentation
  • How-to Guides
    • Official Documentation

      Warning: If you are using User ADCs (Application Default Credentials) with this resource, you must specify a billing_project and set user_project_override to true in the provider configuration. Otherwise the Cloud Identity API will return a 403 error. Your account must have the serviceusage.services.use permission on the billing_project you defined.

Frequently asked questions

What is Google Cloud Identity Group Membership?

Google Cloud Identity Group Membership is a resource for Cloud Identity of Google Cloud Platform. Settings can be wrote in Terraform.

Where can I find the example code for the Google Cloud Identity Group Membership?

For Terraform, the apsureda/ci-groups, apsureda/ci-groups and apsureda/gci-groups source code examples are useful. See the Terraform Example section for further details.

security-icon

Scan your IaC problem in 3 minutes for free

You can keep your IaC security for free. No credit card required.