The gcp:dataplex/entryTypeIamBinding:EntryTypeIamBinding resource, part of the Pulumi GCP provider, manages IAM role bindings for Dataplex EntryType resources. It grants a specific role to a list of members while preserving other roles on the same EntryType. This guide focuses on two capabilities: granting roles to multiple members and adding individual members incrementally.
EntryTypeIamBinding is one of three IAM resources for EntryTypes. It’s authoritative for a single role, meaning it replaces the entire member list for that role. The examples are intentionally small. Combine them with your own EntryType resources and IAM principals.
Grant a role to multiple members at once
Teams managing access often need to grant the same role to multiple users or service accounts simultaneously, such as giving viewer access to an entire team.
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const binding = new gcp.dataplex.EntryTypeIamBinding("binding", {
project: testEntryTypeBasic.project,
location: testEntryTypeBasic.location,
entryTypeId: testEntryTypeBasic.entryTypeId,
role: "roles/viewer",
members: ["user:jane@example.com"],
});
import pulumi
import pulumi_gcp as gcp
binding = gcp.dataplex.EntryTypeIamBinding("binding",
project=test_entry_type_basic["project"],
location=test_entry_type_basic["location"],
entry_type_id=test_entry_type_basic["entryTypeId"],
role="roles/viewer",
members=["user:jane@example.com"])
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/dataplex"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := dataplex.NewEntryTypeIamBinding(ctx, "binding", &dataplex.EntryTypeIamBindingArgs{
Project: pulumi.Any(testEntryTypeBasic.Project),
Location: pulumi.Any(testEntryTypeBasic.Location),
EntryTypeId: pulumi.Any(testEntryTypeBasic.EntryTypeId),
Role: pulumi.String("roles/viewer"),
Members: pulumi.StringArray{
pulumi.String("user:jane@example.com"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var binding = new Gcp.DataPlex.EntryTypeIamBinding("binding", new()
{
Project = testEntryTypeBasic.Project,
Location = testEntryTypeBasic.Location,
EntryTypeId = testEntryTypeBasic.EntryTypeId,
Role = "roles/viewer",
Members = new[]
{
"user:jane@example.com",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.dataplex.EntryTypeIamBinding;
import com.pulumi.gcp.dataplex.EntryTypeIamBindingArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var binding = new EntryTypeIamBinding("binding", EntryTypeIamBindingArgs.builder()
.project(testEntryTypeBasic.project())
.location(testEntryTypeBasic.location())
.entryTypeId(testEntryTypeBasic.entryTypeId())
.role("roles/viewer")
.members("user:jane@example.com")
.build());
}
}
resources:
binding:
type: gcp:dataplex:EntryTypeIamBinding
properties:
project: ${testEntryTypeBasic.project}
location: ${testEntryTypeBasic.location}
entryTypeId: ${testEntryTypeBasic.entryTypeId}
role: roles/viewer
members:
- user:jane@example.com
The members property lists all identities that receive the specified role. EntryTypeIamBinding is authoritative for this role, so it replaces any existing member list. The entryTypeId, location, and project properties identify which EntryType to bind the role to. Member identities can be users, service accounts, groups, domains, or special identifiers like allUsers.
Add a single member to a role incrementally
When onboarding individual users, teams often add them one at a time without affecting other members who already have access.
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const member = new gcp.dataplex.EntryTypeIamMember("member", {
project: testEntryTypeBasic.project,
location: testEntryTypeBasic.location,
entryTypeId: testEntryTypeBasic.entryTypeId,
role: "roles/viewer",
member: "user:jane@example.com",
});
import pulumi
import pulumi_gcp as gcp
member = gcp.dataplex.EntryTypeIamMember("member",
project=test_entry_type_basic["project"],
location=test_entry_type_basic["location"],
entry_type_id=test_entry_type_basic["entryTypeId"],
role="roles/viewer",
member="user:jane@example.com")
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/dataplex"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := dataplex.NewEntryTypeIamMember(ctx, "member", &dataplex.EntryTypeIamMemberArgs{
Project: pulumi.Any(testEntryTypeBasic.Project),
Location: pulumi.Any(testEntryTypeBasic.Location),
EntryTypeId: pulumi.Any(testEntryTypeBasic.EntryTypeId),
Role: pulumi.String("roles/viewer"),
Member: pulumi.String("user:jane@example.com"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var member = new Gcp.DataPlex.EntryTypeIamMember("member", new()
{
Project = testEntryTypeBasic.Project,
Location = testEntryTypeBasic.Location,
EntryTypeId = testEntryTypeBasic.EntryTypeId,
Role = "roles/viewer",
Member = "user:jane@example.com",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.dataplex.EntryTypeIamMember;
import com.pulumi.gcp.dataplex.EntryTypeIamMemberArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var member = new EntryTypeIamMember("member", EntryTypeIamMemberArgs.builder()
.project(testEntryTypeBasic.project())
.location(testEntryTypeBasic.location())
.entryTypeId(testEntryTypeBasic.entryTypeId())
.role("roles/viewer")
.member("user:jane@example.com")
.build());
}
}
resources:
member:
type: gcp:dataplex:EntryTypeIamMember
properties:
project: ${testEntryTypeBasic.project}
location: ${testEntryTypeBasic.location}
entryTypeId: ${testEntryTypeBasic.entryTypeId}
role: roles/viewer
member: user:jane@example.com
The member property (singular) adds one identity to the role. Unlike EntryTypeIamBinding, EntryTypeIamMember is non-authoritative, preserving existing members for the same role. Use this when you need to grant access incrementally without managing the complete member list.
Beyond these examples
These snippets focus on specific EntryType IAM features: role-based access control and batch and incremental member assignment. They’re intentionally minimal rather than full access control configurations.
The examples reference pre-existing infrastructure such as Dataplex EntryType resources and IAM principals (users, service accounts, groups). They focus on configuring IAM bindings rather than provisioning EntryTypes or managing identity providers.
To keep things focused, common IAM patterns are omitted, including:
- Conditional IAM bindings (condition property)
- Complete policy replacement (EntryTypeIamPolicy resource)
- Custom role definitions and formatting
- Federated identity configuration
These omissions are intentional: the goal is to illustrate how EntryType IAM bindings are wired, not provide drop-in access control modules. See the EntryTypeIamBinding resource reference for all available configuration options.
Let's manage GCP Dataplex Entry Type IAM Bindings
Get started with Pulumi Cloud, then follow our quick setup guide to deploy this infrastructure.
Try Pulumi Cloud for FREEFrequently Asked Questions
Resource Selection & Conflicts
EntryTypeIamPolicy is authoritative and replaces the entire IAM policy. EntryTypeIamBinding is authoritative for a specific role, preserving other roles in the policy. EntryTypeIamMember is non-authoritative, adding a single member to a role while preserving other members.EntryTypeIamPolicy cannot be used with EntryTypeIamBinding or EntryTypeIamMember, as they will conflict over the policy. EntryTypeIamBinding and EntryTypeIamMember can be used together only if they manage different roles.Configuration & Formatting
[projects|organizations]/{parent-name}/roles/{role-name}, for example projects/my-project/roles/my-custom-role.members property supports: allUsers, allAuthenticatedUsers, user:{email}, serviceAccount:{email}, group:{email}, domain:{domain}, projectOwner:{projectid}, projectEditor:{projectid}, projectViewer:{projectid}, and federated identities (e.g., principal://iam.googleapis.com/...).EntryTypeIamMember with role set to the desired role and member set to the user identity, such as user:jane@example.com.Resource Properties
entryTypeId, location, project, role, and condition.location and project are parsed from the parent resource identifier. If still unavailable, they’re taken from the provider configuration.