1. Packages
  2. HashiCorp Vault
  3. API Docs
  4. azure
  5. AuthBackendRole
HashiCorp Vault v6.1.1 published on Wednesday, Jun 5, 2024 by Pulumi

vault.azure.AuthBackendRole

Explore with Pulumi AI

vault logo
HashiCorp Vault v6.1.1 published on Wednesday, Jun 5, 2024 by Pulumi

    Manages an Azure auth backend role in a Vault server. Roles constrain the instances or principals that can perform the login operation against the backend. See the Vault documentation for more information.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as vault from "@pulumi/vault";
    
    const azure = new vault.AuthBackend("azure", {type: "azure"});
    const example = new vault.azure.AuthBackendRole("example", {
        backend: azure.path,
        role: "test-role",
        boundSubscriptionIds: ["11111111-2222-3333-4444-555555555555"],
        boundResourceGroups: ["123456789012"],
        tokenTtl: 60,
        tokenMaxTtl: 120,
        tokenPolicies: [
            "default",
            "dev",
            "prod",
        ],
    });
    
    import pulumi
    import pulumi_vault as vault
    
    azure = vault.AuthBackend("azure", type="azure")
    example = vault.azure.AuthBackendRole("example",
        backend=azure.path,
        role="test-role",
        bound_subscription_ids=["11111111-2222-3333-4444-555555555555"],
        bound_resource_groups=["123456789012"],
        token_ttl=60,
        token_max_ttl=120,
        token_policies=[
            "default",
            "dev",
            "prod",
        ])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-vault/sdk/v6/go/vault"
    	"github.com/pulumi/pulumi-vault/sdk/v6/go/vault/azure"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		azure, err := vault.NewAuthBackend(ctx, "azure", &vault.AuthBackendArgs{
    			Type: pulumi.String("azure"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = azure.NewAuthBackendRole(ctx, "example", &azure.AuthBackendRoleArgs{
    			Backend: azure.Path,
    			Role:    pulumi.String("test-role"),
    			BoundSubscriptionIds: pulumi.StringArray{
    				pulumi.String("11111111-2222-3333-4444-555555555555"),
    			},
    			BoundResourceGroups: pulumi.StringArray{
    				pulumi.String("123456789012"),
    			},
    			TokenTtl:    pulumi.Int(60),
    			TokenMaxTtl: pulumi.Int(120),
    			TokenPolicies: pulumi.StringArray{
    				pulumi.String("default"),
    				pulumi.String("dev"),
    				pulumi.String("prod"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Vault = Pulumi.Vault;
    
    return await Deployment.RunAsync(() => 
    {
        var azure = new Vault.AuthBackend("azure", new()
        {
            Type = "azure",
        });
    
        var example = new Vault.Azure.AuthBackendRole("example", new()
        {
            Backend = azure.Path,
            Role = "test-role",
            BoundSubscriptionIds = new[]
            {
                "11111111-2222-3333-4444-555555555555",
            },
            BoundResourceGroups = new[]
            {
                "123456789012",
            },
            TokenTtl = 60,
            TokenMaxTtl = 120,
            TokenPolicies = new[]
            {
                "default",
                "dev",
                "prod",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.vault.AuthBackend;
    import com.pulumi.vault.AuthBackendArgs;
    import com.pulumi.vault.azure.AuthBackendRole;
    import com.pulumi.vault.azure.AuthBackendRoleArgs;
    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 azure = new AuthBackend("azure", AuthBackendArgs.builder()
                .type("azure")
                .build());
    
            var example = new AuthBackendRole("example", AuthBackendRoleArgs.builder()
                .backend(azure.path())
                .role("test-role")
                .boundSubscriptionIds("11111111-2222-3333-4444-555555555555")
                .boundResourceGroups("123456789012")
                .tokenTtl(60)
                .tokenMaxTtl(120)
                .tokenPolicies(            
                    "default",
                    "dev",
                    "prod")
                .build());
    
        }
    }
    
    resources:
      azure:
        type: vault:AuthBackend
        properties:
          type: azure
      example:
        type: vault:azure:AuthBackendRole
        properties:
          backend: ${azure.path}
          role: test-role
          boundSubscriptionIds:
            - 11111111-2222-3333-4444-555555555555
          boundResourceGroups:
            - '123456789012'
          tokenTtl: 60
          tokenMaxTtl: 120
          tokenPolicies:
            - default
            - dev
            - prod
    

    Create AuthBackendRole Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new AuthBackendRole(name: string, args: AuthBackendRoleArgs, opts?: CustomResourceOptions);
    @overload
    def AuthBackendRole(resource_name: str,
                        args: AuthBackendRoleArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def AuthBackendRole(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        role: Optional[str] = None,
                        bound_scale_sets: Optional[Sequence[str]] = None,
                        bound_service_principal_ids: Optional[Sequence[str]] = None,
                        token_bound_cidrs: Optional[Sequence[str]] = None,
                        backend: Optional[str] = None,
                        token_explicit_max_ttl: Optional[int] = None,
                        bound_subscription_ids: Optional[Sequence[str]] = None,
                        namespace: Optional[str] = None,
                        token_max_ttl: Optional[int] = None,
                        bound_resource_groups: Optional[Sequence[str]] = None,
                        bound_locations: Optional[Sequence[str]] = None,
                        bound_group_ids: Optional[Sequence[str]] = None,
                        token_no_default_policy: Optional[bool] = None,
                        token_num_uses: Optional[int] = None,
                        token_period: Optional[int] = None,
                        token_policies: Optional[Sequence[str]] = None,
                        token_ttl: Optional[int] = None,
                        token_type: Optional[str] = None)
    func NewAuthBackendRole(ctx *Context, name string, args AuthBackendRoleArgs, opts ...ResourceOption) (*AuthBackendRole, error)
    public AuthBackendRole(string name, AuthBackendRoleArgs args, CustomResourceOptions? opts = null)
    public AuthBackendRole(String name, AuthBackendRoleArgs args)
    public AuthBackendRole(String name, AuthBackendRoleArgs args, CustomResourceOptions options)
    
    type: vault:azure:AuthBackendRole
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args AuthBackendRoleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args AuthBackendRoleArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args AuthBackendRoleArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AuthBackendRoleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AuthBackendRoleArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var exampleauthBackendRoleResourceResourceFromAzureauthBackendRole = new Vault.Azure.AuthBackendRole("exampleauthBackendRoleResourceResourceFromAzureauthBackendRole", new()
    {
        Role = "string",
        BoundScaleSets = new[]
        {
            "string",
        },
        BoundServicePrincipalIds = new[]
        {
            "string",
        },
        TokenBoundCidrs = new[]
        {
            "string",
        },
        Backend = "string",
        TokenExplicitMaxTtl = 0,
        BoundSubscriptionIds = new[]
        {
            "string",
        },
        Namespace = "string",
        TokenMaxTtl = 0,
        BoundResourceGroups = new[]
        {
            "string",
        },
        BoundLocations = new[]
        {
            "string",
        },
        BoundGroupIds = new[]
        {
            "string",
        },
        TokenNoDefaultPolicy = false,
        TokenNumUses = 0,
        TokenPeriod = 0,
        TokenPolicies = new[]
        {
            "string",
        },
        TokenTtl = 0,
        TokenType = "string",
    });
    
    example, err := azure.NewAuthBackendRole(ctx, "exampleauthBackendRoleResourceResourceFromAzureauthBackendRole", &azure.AuthBackendRoleArgs{
    	Role: pulumi.String("string"),
    	BoundScaleSets: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	BoundServicePrincipalIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	TokenBoundCidrs: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Backend:             pulumi.String("string"),
    	TokenExplicitMaxTtl: pulumi.Int(0),
    	BoundSubscriptionIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Namespace:   pulumi.String("string"),
    	TokenMaxTtl: pulumi.Int(0),
    	BoundResourceGroups: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	BoundLocations: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	BoundGroupIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	TokenNoDefaultPolicy: pulumi.Bool(false),
    	TokenNumUses:         pulumi.Int(0),
    	TokenPeriod:          pulumi.Int(0),
    	TokenPolicies: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	TokenTtl:  pulumi.Int(0),
    	TokenType: pulumi.String("string"),
    })
    
    var exampleauthBackendRoleResourceResourceFromAzureauthBackendRole = new AuthBackendRole("exampleauthBackendRoleResourceResourceFromAzureauthBackendRole", AuthBackendRoleArgs.builder()
        .role("string")
        .boundScaleSets("string")
        .boundServicePrincipalIds("string")
        .tokenBoundCidrs("string")
        .backend("string")
        .tokenExplicitMaxTtl(0)
        .boundSubscriptionIds("string")
        .namespace("string")
        .tokenMaxTtl(0)
        .boundResourceGroups("string")
        .boundLocations("string")
        .boundGroupIds("string")
        .tokenNoDefaultPolicy(false)
        .tokenNumUses(0)
        .tokenPeriod(0)
        .tokenPolicies("string")
        .tokenTtl(0)
        .tokenType("string")
        .build());
    
    exampleauth_backend_role_resource_resource_from_azureauth_backend_role = vault.azure.AuthBackendRole("exampleauthBackendRoleResourceResourceFromAzureauthBackendRole",
        role="string",
        bound_scale_sets=["string"],
        bound_service_principal_ids=["string"],
        token_bound_cidrs=["string"],
        backend="string",
        token_explicit_max_ttl=0,
        bound_subscription_ids=["string"],
        namespace="string",
        token_max_ttl=0,
        bound_resource_groups=["string"],
        bound_locations=["string"],
        bound_group_ids=["string"],
        token_no_default_policy=False,
        token_num_uses=0,
        token_period=0,
        token_policies=["string"],
        token_ttl=0,
        token_type="string")
    
    const exampleauthBackendRoleResourceResourceFromAzureauthBackendRole = new vault.azure.AuthBackendRole("exampleauthBackendRoleResourceResourceFromAzureauthBackendRole", {
        role: "string",
        boundScaleSets: ["string"],
        boundServicePrincipalIds: ["string"],
        tokenBoundCidrs: ["string"],
        backend: "string",
        tokenExplicitMaxTtl: 0,
        boundSubscriptionIds: ["string"],
        namespace: "string",
        tokenMaxTtl: 0,
        boundResourceGroups: ["string"],
        boundLocations: ["string"],
        boundGroupIds: ["string"],
        tokenNoDefaultPolicy: false,
        tokenNumUses: 0,
        tokenPeriod: 0,
        tokenPolicies: ["string"],
        tokenTtl: 0,
        tokenType: "string",
    });
    
    type: vault:azure:AuthBackendRole
    properties:
        backend: string
        boundGroupIds:
            - string
        boundLocations:
            - string
        boundResourceGroups:
            - string
        boundScaleSets:
            - string
        boundServicePrincipalIds:
            - string
        boundSubscriptionIds:
            - string
        namespace: string
        role: string
        tokenBoundCidrs:
            - string
        tokenExplicitMaxTtl: 0
        tokenMaxTtl: 0
        tokenNoDefaultPolicy: false
        tokenNumUses: 0
        tokenPeriod: 0
        tokenPolicies:
            - string
        tokenTtl: 0
        tokenType: string
    

    AuthBackendRole Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The AuthBackendRole resource accepts the following input properties:

    Role string
    The name of the role.
    Backend string
    Unique name of the auth backend to configure.
    BoundGroupIds List<string>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    BoundLocations List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    BoundResourceGroups List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    BoundScaleSets List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    BoundServicePrincipalIds List<string>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    BoundSubscriptionIds List<string>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    Namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    TokenBoundCidrs List<string>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    TokenExplicitMaxTtl int
    Generated Token's Explicit Maximum TTL in seconds
    TokenMaxTtl int
    The maximum lifetime of the generated token
    TokenNoDefaultPolicy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    TokenNumUses int
    The maximum number of times a token may be used, a value of zero means unlimited
    TokenPeriod int
    Generated Token's Period
    TokenPolicies List<string>
    Generated Token's Policies
    TokenTtl int
    The initial ttl of the token to generate in seconds
    TokenType string
    The type of token to generate, service or batch
    Role string
    The name of the role.
    Backend string
    Unique name of the auth backend to configure.
    BoundGroupIds []string
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    BoundLocations []string
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    BoundResourceGroups []string
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    BoundScaleSets []string
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    BoundServicePrincipalIds []string
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    BoundSubscriptionIds []string
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    Namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    TokenBoundCidrs []string
    Specifies the blocks of IP addresses which are allowed to use the generated token
    TokenExplicitMaxTtl int
    Generated Token's Explicit Maximum TTL in seconds
    TokenMaxTtl int
    The maximum lifetime of the generated token
    TokenNoDefaultPolicy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    TokenNumUses int
    The maximum number of times a token may be used, a value of zero means unlimited
    TokenPeriod int
    Generated Token's Period
    TokenPolicies []string
    Generated Token's Policies
    TokenTtl int
    The initial ttl of the token to generate in seconds
    TokenType string
    The type of token to generate, service or batch
    role String
    The name of the role.
    backend String
    Unique name of the auth backend to configure.
    boundGroupIds List<String>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds List<String>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds List<String>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace String
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    tokenBoundCidrs List<String>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl Integer
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl Integer
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy Boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses Integer
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod Integer
    Generated Token's Period
    tokenPolicies List<String>
    Generated Token's Policies
    tokenTtl Integer
    The initial ttl of the token to generate in seconds
    tokenType String
    The type of token to generate, service or batch
    role string
    The name of the role.
    backend string
    Unique name of the auth backend to configure.
    boundGroupIds string[]
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds string[]
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds string[]
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    tokenBoundCidrs string[]
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl number
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl number
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses number
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod number
    Generated Token's Period
    tokenPolicies string[]
    Generated Token's Policies
    tokenTtl number
    The initial ttl of the token to generate in seconds
    tokenType string
    The type of token to generate, service or batch
    role str
    The name of the role.
    backend str
    Unique name of the auth backend to configure.
    bound_group_ids Sequence[str]
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    bound_locations Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    bound_resource_groups Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    bound_scale_sets Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    bound_service_principal_ids Sequence[str]
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    bound_subscription_ids Sequence[str]
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace str
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    token_bound_cidrs Sequence[str]
    Specifies the blocks of IP addresses which are allowed to use the generated token
    token_explicit_max_ttl int
    Generated Token's Explicit Maximum TTL in seconds
    token_max_ttl int
    The maximum lifetime of the generated token
    token_no_default_policy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    token_num_uses int
    The maximum number of times a token may be used, a value of zero means unlimited
    token_period int
    Generated Token's Period
    token_policies Sequence[str]
    Generated Token's Policies
    token_ttl int
    The initial ttl of the token to generate in seconds
    token_type str
    The type of token to generate, service or batch
    role String
    The name of the role.
    backend String
    Unique name of the auth backend to configure.
    boundGroupIds List<String>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds List<String>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds List<String>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace String
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    tokenBoundCidrs List<String>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl Number
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl Number
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy Boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses Number
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod Number
    Generated Token's Period
    tokenPolicies List<String>
    Generated Token's Policies
    tokenTtl Number
    The initial ttl of the token to generate in seconds
    tokenType String
    The type of token to generate, service or batch

    Outputs

    All input properties are implicitly available as output properties. Additionally, the AuthBackendRole resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing AuthBackendRole Resource

    Get an existing AuthBackendRole resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: AuthBackendRoleState, opts?: CustomResourceOptions): AuthBackendRole
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            backend: Optional[str] = None,
            bound_group_ids: Optional[Sequence[str]] = None,
            bound_locations: Optional[Sequence[str]] = None,
            bound_resource_groups: Optional[Sequence[str]] = None,
            bound_scale_sets: Optional[Sequence[str]] = None,
            bound_service_principal_ids: Optional[Sequence[str]] = None,
            bound_subscription_ids: Optional[Sequence[str]] = None,
            namespace: Optional[str] = None,
            role: Optional[str] = None,
            token_bound_cidrs: Optional[Sequence[str]] = None,
            token_explicit_max_ttl: Optional[int] = None,
            token_max_ttl: Optional[int] = None,
            token_no_default_policy: Optional[bool] = None,
            token_num_uses: Optional[int] = None,
            token_period: Optional[int] = None,
            token_policies: Optional[Sequence[str]] = None,
            token_ttl: Optional[int] = None,
            token_type: Optional[str] = None) -> AuthBackendRole
    func GetAuthBackendRole(ctx *Context, name string, id IDInput, state *AuthBackendRoleState, opts ...ResourceOption) (*AuthBackendRole, error)
    public static AuthBackendRole Get(string name, Input<string> id, AuthBackendRoleState? state, CustomResourceOptions? opts = null)
    public static AuthBackendRole get(String name, Output<String> id, AuthBackendRoleState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Backend string
    Unique name of the auth backend to configure.
    BoundGroupIds List<string>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    BoundLocations List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    BoundResourceGroups List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    BoundScaleSets List<string>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    BoundServicePrincipalIds List<string>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    BoundSubscriptionIds List<string>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    Namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    Role string
    The name of the role.
    TokenBoundCidrs List<string>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    TokenExplicitMaxTtl int
    Generated Token's Explicit Maximum TTL in seconds
    TokenMaxTtl int
    The maximum lifetime of the generated token
    TokenNoDefaultPolicy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    TokenNumUses int
    The maximum number of times a token may be used, a value of zero means unlimited
    TokenPeriod int
    Generated Token's Period
    TokenPolicies List<string>
    Generated Token's Policies
    TokenTtl int
    The initial ttl of the token to generate in seconds
    TokenType string
    The type of token to generate, service or batch
    Backend string
    Unique name of the auth backend to configure.
    BoundGroupIds []string
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    BoundLocations []string
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    BoundResourceGroups []string
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    BoundScaleSets []string
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    BoundServicePrincipalIds []string
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    BoundSubscriptionIds []string
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    Namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    Role string
    The name of the role.
    TokenBoundCidrs []string
    Specifies the blocks of IP addresses which are allowed to use the generated token
    TokenExplicitMaxTtl int
    Generated Token's Explicit Maximum TTL in seconds
    TokenMaxTtl int
    The maximum lifetime of the generated token
    TokenNoDefaultPolicy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    TokenNumUses int
    The maximum number of times a token may be used, a value of zero means unlimited
    TokenPeriod int
    Generated Token's Period
    TokenPolicies []string
    Generated Token's Policies
    TokenTtl int
    The initial ttl of the token to generate in seconds
    TokenType string
    The type of token to generate, service or batch
    backend String
    Unique name of the auth backend to configure.
    boundGroupIds List<String>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds List<String>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds List<String>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace String
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    role String
    The name of the role.
    tokenBoundCidrs List<String>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl Integer
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl Integer
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy Boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses Integer
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod Integer
    Generated Token's Period
    tokenPolicies List<String>
    Generated Token's Policies
    tokenTtl Integer
    The initial ttl of the token to generate in seconds
    tokenType String
    The type of token to generate, service or batch
    backend string
    Unique name of the auth backend to configure.
    boundGroupIds string[]
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets string[]
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds string[]
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds string[]
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace string
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    role string
    The name of the role.
    tokenBoundCidrs string[]
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl number
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl number
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses number
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod number
    Generated Token's Period
    tokenPolicies string[]
    Generated Token's Policies
    tokenTtl number
    The initial ttl of the token to generate in seconds
    tokenType string
    The type of token to generate, service or batch
    backend str
    Unique name of the auth backend to configure.
    bound_group_ids Sequence[str]
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    bound_locations Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    bound_resource_groups Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    bound_scale_sets Sequence[str]
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    bound_service_principal_ids Sequence[str]
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    bound_subscription_ids Sequence[str]
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace str
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    role str
    The name of the role.
    token_bound_cidrs Sequence[str]
    Specifies the blocks of IP addresses which are allowed to use the generated token
    token_explicit_max_ttl int
    Generated Token's Explicit Maximum TTL in seconds
    token_max_ttl int
    The maximum lifetime of the generated token
    token_no_default_policy bool
    If true, the 'default' policy will not automatically be added to generated tokens
    token_num_uses int
    The maximum number of times a token may be used, a value of zero means unlimited
    token_period int
    Generated Token's Period
    token_policies Sequence[str]
    Generated Token's Policies
    token_ttl int
    The initial ttl of the token to generate in seconds
    token_type str
    The type of token to generate, service or batch
    backend String
    Unique name of the auth backend to configure.
    boundGroupIds List<String>
    If set, defines a constraint on the groups that can perform the login operation that they should be using the group ID specified by this field.
    boundLocations List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that the location in their identity document must match the one specified by this field.
    boundResourceGroups List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they be associated with the resource group that matches the value specified by this field.
    boundScaleSets List<String>
    If set, defines a constraint on the virtual machines that can perform the login operation that they must match the scale set specified by this field.
    boundServicePrincipalIds List<String>
    If set, defines a constraint on the service principals that can perform the login operation that they should be possess the ids specified by this field.
    boundSubscriptionIds List<String>
    If set, defines a constraint on the subscriptions that can perform the login operation to ones which matches the value specified by this field.
    namespace String
    The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.
    role String
    The name of the role.
    tokenBoundCidrs List<String>
    Specifies the blocks of IP addresses which are allowed to use the generated token
    tokenExplicitMaxTtl Number
    Generated Token's Explicit Maximum TTL in seconds
    tokenMaxTtl Number
    The maximum lifetime of the generated token
    tokenNoDefaultPolicy Boolean
    If true, the 'default' policy will not automatically be added to generated tokens
    tokenNumUses Number
    The maximum number of times a token may be used, a value of zero means unlimited
    tokenPeriod Number
    Generated Token's Period
    tokenPolicies List<String>
    Generated Token's Policies
    tokenTtl Number
    The initial ttl of the token to generate in seconds
    tokenType String
    The type of token to generate, service or batch

    Import

    Azure auth backend roles can be imported using auth/, the backend path, /role/, and the role name e.g.

    $ pulumi import vault:azure/authBackendRole:AuthBackendRole example auth/azure/role/test-role
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Vault pulumi/pulumi-vault
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the vault Terraform Provider.
    vault logo
    HashiCorp Vault v6.1.1 published on Wednesday, Jun 5, 2024 by Pulumi