1. Packages
  2. Alks Provider
  3. API Docs
  4. Iamrole
alks 2.8.2 published on Monday, Apr 14, 2025 by cox-automotive

alks.Iamrole

Explore with Pulumi AI

alks logo
alks 2.8.2 published on Monday, Apr 14, 2025 by cox-automotive

    Import

    !> Warning: This will force-replace the resource if using role type method.

    ALKS IAM roles can be imported using the name, e.g.

    $ pulumi import alks:index/iamrole:Iamrole test_role My_Test_Role
    

    Create Iamrole Resource

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

    Constructor syntax

    new Iamrole(name: string, args?: IamroleArgs, opts?: CustomResourceOptions);
    @overload
    def Iamrole(resource_name: str,
                args: Optional[IamroleArgs] = None,
                opts: Optional[ResourceOptions] = None)
    
    @overload
    def Iamrole(resource_name: str,
                opts: Optional[ResourceOptions] = None,
                assume_role_policy: Optional[str] = None,
                enable_alks_access: Optional[bool] = None,
                iamrole_id: Optional[str] = None,
                include_default_policies: Optional[bool] = None,
                max_session_duration_in_seconds: Optional[float] = None,
                name: Optional[str] = None,
                name_prefix: Optional[str] = None,
                tags: Optional[Mapping[str, str]] = None,
                tags_all: Optional[Mapping[str, str]] = None,
                template_fields: Optional[Mapping[str, str]] = None,
                type: Optional[str] = None)
    func NewIamrole(ctx *Context, name string, args *IamroleArgs, opts ...ResourceOption) (*Iamrole, error)
    public Iamrole(string name, IamroleArgs? args = null, CustomResourceOptions? opts = null)
    public Iamrole(String name, IamroleArgs args)
    public Iamrole(String name, IamroleArgs args, CustomResourceOptions options)
    
    type: alks:Iamrole
    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 IamroleArgs
    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 IamroleArgs
    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 IamroleArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args IamroleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args IamroleArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

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

    var iamroleResource = new Alks.Iamrole("iamroleResource", new()
    {
        AssumeRolePolicy = "string",
        EnableAlksAccess = false,
        IamroleId = "string",
        IncludeDefaultPolicies = false,
        MaxSessionDurationInSeconds = 0,
        Name = "string",
        NamePrefix = "string",
        Tags = 
        {
            { "string", "string" },
        },
        TagsAll = 
        {
            { "string", "string" },
        },
        TemplateFields = 
        {
            { "string", "string" },
        },
        Type = "string",
    });
    
    example, err := alks.NewIamrole(ctx, "iamroleResource", &alks.IamroleArgs{
    	AssumeRolePolicy:            pulumi.String("string"),
    	EnableAlksAccess:            pulumi.Bool(false),
    	IamroleId:                   pulumi.String("string"),
    	IncludeDefaultPolicies:      pulumi.Bool(false),
    	MaxSessionDurationInSeconds: pulumi.Float64(0),
    	Name:                        pulumi.String("string"),
    	NamePrefix:                  pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	TagsAll: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	TemplateFields: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	Type: pulumi.String("string"),
    })
    
    var iamroleResource = new Iamrole("iamroleResource", IamroleArgs.builder()
        .assumeRolePolicy("string")
        .enableAlksAccess(false)
        .iamroleId("string")
        .includeDefaultPolicies(false)
        .maxSessionDurationInSeconds(0)
        .name("string")
        .namePrefix("string")
        .tags(Map.of("string", "string"))
        .tagsAll(Map.of("string", "string"))
        .templateFields(Map.of("string", "string"))
        .type("string")
        .build());
    
    iamrole_resource = alks.Iamrole("iamroleResource",
        assume_role_policy="string",
        enable_alks_access=False,
        iamrole_id="string",
        include_default_policies=False,
        max_session_duration_in_seconds=0,
        name="string",
        name_prefix="string",
        tags={
            "string": "string",
        },
        tags_all={
            "string": "string",
        },
        template_fields={
            "string": "string",
        },
        type="string")
    
    const iamroleResource = new alks.Iamrole("iamroleResource", {
        assumeRolePolicy: "string",
        enableAlksAccess: false,
        iamroleId: "string",
        includeDefaultPolicies: false,
        maxSessionDurationInSeconds: 0,
        name: "string",
        namePrefix: "string",
        tags: {
            string: "string",
        },
        tagsAll: {
            string: "string",
        },
        templateFields: {
            string: "string",
        },
        type: "string",
    });
    
    type: alks:Iamrole
    properties:
        assumeRolePolicy: string
        enableAlksAccess: false
        iamroleId: string
        includeDefaultPolicies: false
        maxSessionDurationInSeconds: 0
        name: string
        namePrefix: string
        tags:
            string: string
        tagsAll:
            string: string
        templateFields:
            string: string
        type: string
    

    Iamrole Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Iamrole resource accepts the following input properties:

    AssumeRolePolicy string
    EnableAlksAccess bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    IamroleId string
    IncludeDefaultPolicies bool
    Whether or not the default manages policies should be attached to the role.
    MaxSessionDurationInSeconds double
    If present, will set maximum duration for role. Change forces re-creation of resource.
    Name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    NamePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    Tags Dictionary<string, string>
    If present, will add specified tags onto role.
    TagsAll Dictionary<string, string>
    TemplateFields Dictionary<string, string>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    Type string
    The role type to use. To see a list of available roles, call this endpoint.
    AssumeRolePolicy string
    EnableAlksAccess bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    IamroleId string
    IncludeDefaultPolicies bool
    Whether or not the default manages policies should be attached to the role.
    MaxSessionDurationInSeconds float64
    If present, will set maximum duration for role. Change forces re-creation of resource.
    Name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    NamePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    Tags map[string]string
    If present, will add specified tags onto role.
    TagsAll map[string]string
    TemplateFields map[string]string
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    Type string
    The role type to use. To see a list of available roles, call this endpoint.
    assumeRolePolicy String
    enableAlksAccess Boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId String
    includeDefaultPolicies Boolean
    Whether or not the default manages policies should be attached to the role.
    maxSessionDurationInSeconds Double
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name String
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix String
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    tags Map<String,String>
    If present, will add specified tags onto role.
    tagsAll Map<String,String>
    templateFields Map<String,String>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type String
    The role type to use. To see a list of available roles, call this endpoint.
    assumeRolePolicy string
    enableAlksAccess boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId string
    includeDefaultPolicies boolean
    Whether or not the default manages policies should be attached to the role.
    maxSessionDurationInSeconds number
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    tags {[key: string]: string}
    If present, will add specified tags onto role.
    tagsAll {[key: string]: string}
    templateFields {[key: string]: string}
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type string
    The role type to use. To see a list of available roles, call this endpoint.
    assume_role_policy str
    enable_alks_access bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamrole_id str
    include_default_policies bool
    Whether or not the default manages policies should be attached to the role.
    max_session_duration_in_seconds float
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name str
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    name_prefix str
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    tags Mapping[str, str]
    If present, will add specified tags onto role.
    tags_all Mapping[str, str]
    template_fields Mapping[str, str]
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type str
    The role type to use. To see a list of available roles, call this endpoint.
    assumeRolePolicy String
    enableAlksAccess Boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId String
    includeDefaultPolicies Boolean
    Whether or not the default manages policies should be attached to the role.
    maxSessionDurationInSeconds Number
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name String
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix String
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    tags Map<String>
    If present, will add specified tags onto role.
    tagsAll Map<String>
    templateFields Map<String>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type String
    The role type to use. To see a list of available roles, call this endpoint.

    Outputs

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

    Arn string
    Provides the ARN of the role that was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    IpArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    RoleAddedToIp bool
    Indicates whether or not an instance profile role was created.
    Arn string
    Provides the ARN of the role that was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    IpArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    RoleAddedToIp bool
    Indicates whether or not an instance profile role was created.
    arn String
    Provides the ARN of the role that was created.
    id String
    The provider-assigned unique ID for this managed resource.
    ipArn String
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    roleAddedToIp Boolean
    Indicates whether or not an instance profile role was created.
    arn string
    Provides the ARN of the role that was created.
    id string
    The provider-assigned unique ID for this managed resource.
    ipArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    roleAddedToIp boolean
    Indicates whether or not an instance profile role was created.
    arn str
    Provides the ARN of the role that was created.
    id str
    The provider-assigned unique ID for this managed resource.
    ip_arn str
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    role_added_to_ip bool
    Indicates whether or not an instance profile role was created.
    arn String
    Provides the ARN of the role that was created.
    id String
    The provider-assigned unique ID for this managed resource.
    ipArn String
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    roleAddedToIp Boolean
    Indicates whether or not an instance profile role was created.

    Look up Existing Iamrole Resource

    Get an existing Iamrole 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?: IamroleState, opts?: CustomResourceOptions): Iamrole
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            arn: Optional[str] = None,
            assume_role_policy: Optional[str] = None,
            enable_alks_access: Optional[bool] = None,
            iamrole_id: Optional[str] = None,
            include_default_policies: Optional[bool] = None,
            ip_arn: Optional[str] = None,
            max_session_duration_in_seconds: Optional[float] = None,
            name: Optional[str] = None,
            name_prefix: Optional[str] = None,
            role_added_to_ip: Optional[bool] = None,
            tags: Optional[Mapping[str, str]] = None,
            tags_all: Optional[Mapping[str, str]] = None,
            template_fields: Optional[Mapping[str, str]] = None,
            type: Optional[str] = None) -> Iamrole
    func GetIamrole(ctx *Context, name string, id IDInput, state *IamroleState, opts ...ResourceOption) (*Iamrole, error)
    public static Iamrole Get(string name, Input<string> id, IamroleState? state, CustomResourceOptions? opts = null)
    public static Iamrole get(String name, Output<String> id, IamroleState state, CustomResourceOptions options)
    resources:  _:    type: alks:Iamrole    get:      id: ${id}
    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:
    Arn string
    Provides the ARN of the role that was created.
    AssumeRolePolicy string
    EnableAlksAccess bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    IamroleId string
    IncludeDefaultPolicies bool
    Whether or not the default manages policies should be attached to the role.
    IpArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    MaxSessionDurationInSeconds double
    If present, will set maximum duration for role. Change forces re-creation of resource.
    Name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    NamePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    RoleAddedToIp bool
    Indicates whether or not an instance profile role was created.
    Tags Dictionary<string, string>
    If present, will add specified tags onto role.
    TagsAll Dictionary<string, string>
    TemplateFields Dictionary<string, string>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    Type string
    The role type to use. To see a list of available roles, call this endpoint.
    Arn string
    Provides the ARN of the role that was created.
    AssumeRolePolicy string
    EnableAlksAccess bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    IamroleId string
    IncludeDefaultPolicies bool
    Whether or not the default manages policies should be attached to the role.
    IpArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    MaxSessionDurationInSeconds float64
    If present, will set maximum duration for role. Change forces re-creation of resource.
    Name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    NamePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    RoleAddedToIp bool
    Indicates whether or not an instance profile role was created.
    Tags map[string]string
    If present, will add specified tags onto role.
    TagsAll map[string]string
    TemplateFields map[string]string
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    Type string
    The role type to use. To see a list of available roles, call this endpoint.
    arn String
    Provides the ARN of the role that was created.
    assumeRolePolicy String
    enableAlksAccess Boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId String
    includeDefaultPolicies Boolean
    Whether or not the default manages policies should be attached to the role.
    ipArn String
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    maxSessionDurationInSeconds Double
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name String
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix String
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    roleAddedToIp Boolean
    Indicates whether or not an instance profile role was created.
    tags Map<String,String>
    If present, will add specified tags onto role.
    tagsAll Map<String,String>
    templateFields Map<String,String>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type String
    The role type to use. To see a list of available roles, call this endpoint.
    arn string
    Provides the ARN of the role that was created.
    assumeRolePolicy string
    enableAlksAccess boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId string
    includeDefaultPolicies boolean
    Whether or not the default manages policies should be attached to the role.
    ipArn string
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    maxSessionDurationInSeconds number
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name string
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix string
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    roleAddedToIp boolean
    Indicates whether or not an instance profile role was created.
    tags {[key: string]: string}
    If present, will add specified tags onto role.
    tagsAll {[key: string]: string}
    templateFields {[key: string]: string}
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type string
    The role type to use. To see a list of available roles, call this endpoint.
    arn str
    Provides the ARN of the role that was created.
    assume_role_policy str
    enable_alks_access bool
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamrole_id str
    include_default_policies bool
    Whether or not the default manages policies should be attached to the role.
    ip_arn str
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    max_session_duration_in_seconds float
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name str
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    name_prefix str
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    role_added_to_ip bool
    Indicates whether or not an instance profile role was created.
    tags Mapping[str, str]
    If present, will add specified tags onto role.
    tags_all Mapping[str, str]
    template_fields Mapping[str, str]
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type str
    The role type to use. To see a list of available roles, call this endpoint.
    arn String
    Provides the ARN of the role that was created.
    assumeRolePolicy String
    enableAlksAccess Boolean
    If true, allows ALKS calls to be made by instance profiles or Lambda functions making use of this role. Note: This enables machine identity capability.
    iamroleId String
    includeDefaultPolicies Boolean
    Whether or not the default manages policies should be attached to the role.
    ipArn String
    If role_added_to_ip was true this will provide the ARN of the instance profile role.
    maxSessionDurationInSeconds Number
    If present, will set maximum duration for role. Change forces re-creation of resource.
    name String
    The name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    namePrefix String
    A prefix for a generated name of the ALKS IAM role which will be reflected in AWS and the ALKS UI.
    roleAddedToIp Boolean
    Indicates whether or not an instance profile role was created.
    tags Map<String>
    If present, will add specified tags onto role.
    tagsAll Map<String>
    templateFields Map<String>
    If present, will submit template field data to ALKS. Note: This will generate an error if the role type does not support template fields.
    type String
    The role type to use. To see a list of available roles, call this endpoint.

    Package Details

    Repository
    alks cox-automotive/terraform-provider-alks
    License
    Notes
    This Pulumi package is based on the alks Terraform Provider.
    alks logo
    alks 2.8.2 published on Monday, Apr 14, 2025 by cox-automotive