1. Packages
  2. Confluent Cloud
  3. API Docs
  4. getRoleBinding
Confluent v2.3.0 published on Friday, Sep 27, 2024 by Pulumi

confluentcloud.getRoleBinding

Explore with Pulumi AI

confluentcloud logo
Confluent v2.3.0 published on Friday, Sep 27, 2024 by Pulumi

    General Availability

    confluentcloud.RoleBinding describes a Role Binding.

    Note: For more information on the Role Bindings, see Predefined RBAC roles in Confluent Cloud.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as confluentcloud from "@pulumi/confluentcloud";
    
    export = async () => {
        const example = await confluentcloud.getRoleBinding({
            id: "rb-abc123",
        });
        return {
            example: example,
        };
    }
    
    import pulumi
    import pulumi_confluentcloud as confluentcloud
    
    example = confluentcloud.get_role_binding(id="rb-abc123")
    pulumi.export("example", example)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-confluentcloud/sdk/v2/go/confluentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := confluentcloud.LookupRoleBinding(ctx, &confluentcloud.LookupRoleBindingArgs{
    			Id: "rb-abc123",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("example", example)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ConfluentCloud = Pulumi.ConfluentCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = ConfluentCloud.GetRoleBinding.Invoke(new()
        {
            Id = "rb-abc123",
        });
    
        return new Dictionary<string, object?>
        {
            ["example"] = example,
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.confluentcloud.ConfluentcloudFunctions;
    import com.pulumi.confluentcloud.inputs.GetRoleBindingArgs;
    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) {
            final var example = ConfluentcloudFunctions.getRoleBinding(GetRoleBindingArgs.builder()
                .id("rb-abc123")
                .build());
    
            ctx.export("example", example.applyValue(getRoleBindingResult -> getRoleBindingResult));
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: confluentcloud:getRoleBinding
          Arguments:
            id: rb-abc123
    outputs:
      example: ${example}
    

    Using getRoleBinding

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getRoleBinding(args: GetRoleBindingArgs, opts?: InvokeOptions): Promise<GetRoleBindingResult>
    function getRoleBindingOutput(args: GetRoleBindingOutputArgs, opts?: InvokeOptions): Output<GetRoleBindingResult>
    def get_role_binding(id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetRoleBindingResult
    def get_role_binding_output(id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetRoleBindingResult]
    func LookupRoleBinding(ctx *Context, args *LookupRoleBindingArgs, opts ...InvokeOption) (*LookupRoleBindingResult, error)
    func LookupRoleBindingOutput(ctx *Context, args *LookupRoleBindingOutputArgs, opts ...InvokeOption) LookupRoleBindingResultOutput

    > Note: This function is named LookupRoleBinding in the Go SDK.

    public static class GetRoleBinding 
    {
        public static Task<GetRoleBindingResult> InvokeAsync(GetRoleBindingArgs args, InvokeOptions? opts = null)
        public static Output<GetRoleBindingResult> Invoke(GetRoleBindingInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetRoleBindingResult> getRoleBinding(GetRoleBindingArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: confluentcloud:index/getRoleBinding:getRoleBinding
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    The ID of the Role Binding (for example, rb-abc123).
    Id string
    The ID of the Role Binding (for example, rb-abc123).
    id String
    The ID of the Role Binding (for example, rb-abc123).
    id string
    The ID of the Role Binding (for example, rb-abc123).
    id str
    The ID of the Role Binding (for example, rb-abc123).
    id String
    The ID of the Role Binding (for example, rb-abc123).

    getRoleBinding Result

    The following output properties are available:

    CrnPattern string
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    Id string
    Principal string
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    RoleName string
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.
    CrnPattern string
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    Id string
    Principal string
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    RoleName string
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.
    crnPattern String
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    id String
    principal String
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    roleName String
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.
    crnPattern string
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    id string
    principal string
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    roleName string
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.
    crn_pattern str
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    id str
    principal str
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    role_name str
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.
    crnPattern String
    (Required String) A Confluent Resource Name(CRN) that specifies the scope and resource patterns necessary for the role to bind.
    id String
    principal String
    (Required String) A principal User to bind the role to, for example, "User:u-111aaa" for binding to a user "u-111aaa", or "User:sa-111aaa" for binding to a service account "sa-111aaa".
    roleName String
    (Required String) A name of the role to bind to the principal. See Confluent Cloud RBAC Roles for a full list of supported role names.

    Package Details

    Repository
    Confluent Cloud pulumi/pulumi-confluentcloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the confluent Terraform Provider.
    confluentcloud logo
    Confluent v2.3.0 published on Friday, Sep 27, 2024 by Pulumi