ibm.IamPolicyAssignment
Explore with Pulumi AI
Create, update, and delete policy_assignments with this resource.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const policyS2sTemplate = new ibm.IamPolicyTemplate("policyS2sTemplate", {
policy: {
type: "authorization",
description: "description",
resources: [{
attributes: [{
key: "serviceName",
operator: "stringEquals",
value: "kms",
}],
}],
subjects: [{
attributes: [{
key: "serviceName",
operator: "stringEquals",
value: "compliance",
}],
}],
roles: ["Reader"],
},
committed: true,
});
const templateVersion = new ibm.IamPolicyTemplateVersion("templateVersion", {
templateId: policyS2sTemplate.templateId,
policy: {
type: "authorization",
description: "description",
resource: {
attributes: [{
key: "serviceName",
operator: "stringEquals",
value: "appid",
}],
},
subjects: [{
attributes: [{
key: "serviceName",
operator: "stringEquals",
value: "compliance",
}],
}],
roles: ["Reader"],
},
committed: true,
});
const policyAssignmentIamPolicyAssignment = new ibm.IamPolicyAssignment("policyAssignmentIamPolicyAssignment", {
version: "1.0",
target: {
type: "Account",
id: "<target-accountId>",
},
templates: {
id: policyS2sTemplate.templateId,
version: policyS2sTemplate.version,
},
templateVersion: templateVersion.version,
});
const policyAssignmentIndex_iamPolicyAssignmentIamPolicyAssignment = new ibm.IamPolicyAssignment("policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment", {
version: "1.0",
target: {
type: "Account Group",
id: "<target-accountgroupId>",
},
templates: {
id: policyS2sTemplate.templateId,
version: policyS2sTemplate.version,
},
templateVersion: templateVersion.version,
});
const policyAssignmentIbmIndex_iamPolicyAssignmentIamPolicyAssignment = new ibm.IamPolicyAssignment("policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment", {
version: "1.0",
target: {
type: "Enterprise",
id: "<target-enterpriseId>",
},
templates: {
id: policyS2sTemplate.templateId,
version: policyS2sTemplate.version,
},
templateVersion: templateVersion.version,
});
import pulumi
import pulumi_ibm as ibm
policy_s2s_template = ibm.IamPolicyTemplate("policyS2sTemplate",
policy={
"type": "authorization",
"description": "description",
"resources": [{
"attributes": [{
"key": "serviceName",
"operator": "stringEquals",
"value": "kms",
}],
}],
"subjects": [{
"attributes": [{
"key": "serviceName",
"operator": "stringEquals",
"value": "compliance",
}],
}],
"roles": ["Reader"],
},
committed=True)
template_version = ibm.IamPolicyTemplateVersion("templateVersion",
template_id=policy_s2s_template.template_id,
policy={
"type": "authorization",
"description": "description",
"resource": {
"attributes": [{
"key": "serviceName",
"operator": "stringEquals",
"value": "appid",
}],
},
"subjects": [{
"attributes": [{
"key": "serviceName",
"operator": "stringEquals",
"value": "compliance",
}],
}],
"roles": ["Reader"],
},
committed=True)
policy_assignment_iam_policy_assignment = ibm.IamPolicyAssignment("policyAssignmentIamPolicyAssignment",
version="1.0",
target={
"type": "Account",
"id": "<target-accountId>",
},
templates={
"id": policy_s2s_template.template_id,
"version": policy_s2s_template.version,
},
template_version=template_version.version)
policy_assignment_index_iam_policy_assignment_iam_policy_assignment = ibm.IamPolicyAssignment("policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment",
version="1.0",
target={
"type": "Account Group",
"id": "<target-accountgroupId>",
},
templates={
"id": policy_s2s_template.template_id,
"version": policy_s2s_template.version,
},
template_version=template_version.version)
policy_assignment_ibm_index_iam_policy_assignment_iam_policy_assignment = ibm.IamPolicyAssignment("policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment",
version="1.0",
target={
"type": "Enterprise",
"id": "<target-enterpriseId>",
},
templates={
"id": policy_s2s_template.template_id,
"version": policy_s2s_template.version,
},
template_version=template_version.version)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
policyS2sTemplate, err := ibm.NewIamPolicyTemplate(ctx, "policyS2sTemplate", &ibm.IamPolicyTemplateArgs{
Policy: &ibm.IamPolicyTemplatePolicyArgs{
Type: pulumi.String("authorization"),
Description: pulumi.String("description"),
Resources: ibm.IamPolicyTemplatePolicyResourceArray{
&ibm.IamPolicyTemplatePolicyResourceArgs{
Attributes: ibm.IamPolicyTemplatePolicyResourceAttributeArray{
&ibm.IamPolicyTemplatePolicyResourceAttributeArgs{
Key: pulumi.String("serviceName"),
Operator: pulumi.String("stringEquals"),
Value: pulumi.String("kms"),
},
},
},
},
Subjects: ibm.IamPolicyTemplatePolicySubjectArray{
&ibm.IamPolicyTemplatePolicySubjectArgs{
Attributes: ibm.IamPolicyTemplatePolicySubjectAttributeArray{
&ibm.IamPolicyTemplatePolicySubjectAttributeArgs{
Key: pulumi.String("serviceName"),
Operator: pulumi.String("stringEquals"),
Value: pulumi.String("compliance"),
},
},
},
},
Roles: pulumi.StringArray{
pulumi.String("Reader"),
},
},
Committed: pulumi.Bool(true),
})
if err != nil {
return err
}
templateVersion, err := ibm.NewIamPolicyTemplateVersion(ctx, "templateVersion", &ibm.IamPolicyTemplateVersionArgs{
TemplateId: policyS2sTemplate.TemplateId,
Policy: &ibm.IamPolicyTemplateVersionPolicyArgs{
Type: pulumi.String("authorization"),
Description: pulumi.String("description"),
Resource: &ibm.IamPolicyTemplateVersionPolicyResourceArgs{
Attributes: ibm.IamPolicyTemplateVersionPolicyResourceAttributeArray{
&ibm.IamPolicyTemplateVersionPolicyResourceAttributeArgs{
Key: pulumi.String("serviceName"),
Operator: pulumi.String("stringEquals"),
Value: pulumi.String("appid"),
},
},
},
Subjects: ibm.IamPolicyTemplateVersionPolicySubjectArray{
&ibm.IamPolicyTemplateVersionPolicySubjectArgs{
Attributes: ibm.IamPolicyTemplateVersionPolicySubjectAttributeArray{
&ibm.IamPolicyTemplateVersionPolicySubjectAttributeArgs{
Key: pulumi.String("serviceName"),
Operator: pulumi.String("stringEquals"),
Value: pulumi.String("compliance"),
},
},
},
},
Roles: pulumi.StringArray{
pulumi.String("Reader"),
},
},
Committed: pulumi.Bool(true),
})
if err != nil {
return err
}
_, err = ibm.NewIamPolicyAssignment(ctx, "policyAssignmentIamPolicyAssignment", &ibm.IamPolicyAssignmentArgs{
Version: pulumi.String("1.0"),
Target: pulumi.StringMap{
"type": pulumi.String("Account"),
"id": pulumi.String("<target-accountId>"),
},
Templates: &ibm.IamPolicyAssignmentTemplatesArgs{
Id: policyS2sTemplate.TemplateId,
Version: policyS2sTemplate.Version,
},
TemplateVersion: templateVersion.Version,
})
if err != nil {
return err
}
_, err = ibm.NewIamPolicyAssignment(ctx, "policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment", &ibm.IamPolicyAssignmentArgs{
Version: pulumi.String("1.0"),
Target: pulumi.StringMap{
"type": pulumi.String("Account Group"),
"id": pulumi.String("<target-accountgroupId>"),
},
Templates: &ibm.IamPolicyAssignmentTemplatesArgs{
Id: policyS2sTemplate.TemplateId,
Version: policyS2sTemplate.Version,
},
TemplateVersion: templateVersion.Version,
})
if err != nil {
return err
}
_, err = ibm.NewIamPolicyAssignment(ctx, "policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment", &ibm.IamPolicyAssignmentArgs{
Version: pulumi.String("1.0"),
Target: pulumi.StringMap{
"type": pulumi.String("Enterprise"),
"id": pulumi.String("<target-enterpriseId>"),
},
Templates: &ibm.IamPolicyAssignmentTemplatesArgs{
Id: policyS2sTemplate.TemplateId,
Version: policyS2sTemplate.Version,
},
TemplateVersion: templateVersion.Version,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() =>
{
var policyS2sTemplate = new Ibm.IamPolicyTemplate("policyS2sTemplate", new()
{
Policy = new Ibm.Inputs.IamPolicyTemplatePolicyArgs
{
Type = "authorization",
Description = "description",
Resources = new[]
{
new Ibm.Inputs.IamPolicyTemplatePolicyResourceArgs
{
Attributes = new[]
{
new Ibm.Inputs.IamPolicyTemplatePolicyResourceAttributeArgs
{
Key = "serviceName",
Operator = "stringEquals",
Value = "kms",
},
},
},
},
Subjects = new[]
{
new Ibm.Inputs.IamPolicyTemplatePolicySubjectArgs
{
Attributes = new[]
{
new Ibm.Inputs.IamPolicyTemplatePolicySubjectAttributeArgs
{
Key = "serviceName",
Operator = "stringEquals",
Value = "compliance",
},
},
},
},
Roles = new[]
{
"Reader",
},
},
Committed = true,
});
var templateVersion = new Ibm.IamPolicyTemplateVersion("templateVersion", new()
{
TemplateId = policyS2sTemplate.TemplateId,
Policy = new Ibm.Inputs.IamPolicyTemplateVersionPolicyArgs
{
Type = "authorization",
Description = "description",
Resource = new Ibm.Inputs.IamPolicyTemplateVersionPolicyResourceArgs
{
Attributes = new[]
{
new Ibm.Inputs.IamPolicyTemplateVersionPolicyResourceAttributeArgs
{
Key = "serviceName",
Operator = "stringEquals",
Value = "appid",
},
},
},
Subjects = new[]
{
new Ibm.Inputs.IamPolicyTemplateVersionPolicySubjectArgs
{
Attributes = new[]
{
new Ibm.Inputs.IamPolicyTemplateVersionPolicySubjectAttributeArgs
{
Key = "serviceName",
Operator = "stringEquals",
Value = "compliance",
},
},
},
},
Roles = new[]
{
"Reader",
},
},
Committed = true,
});
var policyAssignmentIamPolicyAssignment = new Ibm.IamPolicyAssignment("policyAssignmentIamPolicyAssignment", new()
{
Version = "1.0",
Target =
{
{ "type", "Account" },
{ "id", "<target-accountId>" },
},
Templates = new Ibm.Inputs.IamPolicyAssignmentTemplatesArgs
{
Id = policyS2sTemplate.TemplateId,
Version = policyS2sTemplate.Version,
},
TemplateVersion = templateVersion.Version,
});
var policyAssignmentIndex_iamPolicyAssignmentIamPolicyAssignment = new Ibm.IamPolicyAssignment("policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment", new()
{
Version = "1.0",
Target =
{
{ "type", "Account Group" },
{ "id", "<target-accountgroupId>" },
},
Templates = new Ibm.Inputs.IamPolicyAssignmentTemplatesArgs
{
Id = policyS2sTemplate.TemplateId,
Version = policyS2sTemplate.Version,
},
TemplateVersion = templateVersion.Version,
});
var policyAssignmentIbmIndex_iamPolicyAssignmentIamPolicyAssignment = new Ibm.IamPolicyAssignment("policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment", new()
{
Version = "1.0",
Target =
{
{ "type", "Enterprise" },
{ "id", "<target-enterpriseId>" },
},
Templates = new Ibm.Inputs.IamPolicyAssignmentTemplatesArgs
{
Id = policyS2sTemplate.TemplateId,
Version = policyS2sTemplate.Version,
},
TemplateVersion = templateVersion.Version,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.IamPolicyTemplate;
import com.pulumi.ibm.IamPolicyTemplateArgs;
import com.pulumi.ibm.inputs.IamPolicyTemplatePolicyArgs;
import com.pulumi.ibm.IamPolicyTemplateVersion;
import com.pulumi.ibm.IamPolicyTemplateVersionArgs;
import com.pulumi.ibm.inputs.IamPolicyTemplateVersionPolicyArgs;
import com.pulumi.ibm.inputs.IamPolicyTemplateVersionPolicyResourceArgs;
import com.pulumi.ibm.IamPolicyAssignment;
import com.pulumi.ibm.IamPolicyAssignmentArgs;
import com.pulumi.ibm.inputs.IamPolicyAssignmentTemplatesArgs;
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 policyS2sTemplate = new IamPolicyTemplate("policyS2sTemplate", IamPolicyTemplateArgs.builder()
.policy(IamPolicyTemplatePolicyArgs.builder()
.type("authorization")
.description("description")
.resources(IamPolicyTemplatePolicyResourceArgs.builder()
.attributes(IamPolicyTemplatePolicyResourceAttributeArgs.builder()
.key("serviceName")
.operator("stringEquals")
.value("kms")
.build())
.build())
.subjects(IamPolicyTemplatePolicySubjectArgs.builder()
.attributes(IamPolicyTemplatePolicySubjectAttributeArgs.builder()
.key("serviceName")
.operator("stringEquals")
.value("compliance")
.build())
.build())
.roles("Reader")
.build())
.committed(true)
.build());
var templateVersion = new IamPolicyTemplateVersion("templateVersion", IamPolicyTemplateVersionArgs.builder()
.templateId(policyS2sTemplate.templateId())
.policy(IamPolicyTemplateVersionPolicyArgs.builder()
.type("authorization")
.description("description")
.resource(IamPolicyTemplateVersionPolicyResourceArgs.builder()
.attributes(IamPolicyTemplateVersionPolicyResourceAttributeArgs.builder()
.key("serviceName")
.operator("stringEquals")
.value("appid")
.build())
.build())
.subjects(IamPolicyTemplateVersionPolicySubjectArgs.builder()
.attributes(IamPolicyTemplateVersionPolicySubjectAttributeArgs.builder()
.key("serviceName")
.operator("stringEquals")
.value("compliance")
.build())
.build())
.roles("Reader")
.build())
.committed(true)
.build());
var policyAssignmentIamPolicyAssignment = new IamPolicyAssignment("policyAssignmentIamPolicyAssignment", IamPolicyAssignmentArgs.builder()
.version("1.0")
.target(Map.ofEntries(
Map.entry("type", "Account"),
Map.entry("id", "<target-accountId>")
))
.templates(IamPolicyAssignmentTemplatesArgs.builder()
.id(policyS2sTemplate.templateId())
.version(policyS2sTemplate.version())
.build())
.templateVersion(templateVersion.version())
.build());
var policyAssignmentIndex_iamPolicyAssignmentIamPolicyAssignment = new IamPolicyAssignment("policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment", IamPolicyAssignmentArgs.builder()
.version("1.0")
.target(Map.ofEntries(
Map.entry("type", "Account Group"),
Map.entry("id", "<target-accountgroupId>")
))
.templates(IamPolicyAssignmentTemplatesArgs.builder()
.id(policyS2sTemplate.templateId())
.version(policyS2sTemplate.version())
.build())
.templateVersion(templateVersion.version())
.build());
var policyAssignmentIbmIndex_iamPolicyAssignmentIamPolicyAssignment = new IamPolicyAssignment("policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment", IamPolicyAssignmentArgs.builder()
.version("1.0")
.target(Map.ofEntries(
Map.entry("type", "Enterprise"),
Map.entry("id", "<target-enterpriseId>")
))
.templates(IamPolicyAssignmentTemplatesArgs.builder()
.id(policyS2sTemplate.templateId())
.version(policyS2sTemplate.version())
.build())
.templateVersion(templateVersion.version())
.build());
}
}
resources:
policyS2sTemplate:
type: ibm:IamPolicyTemplate
properties:
policy:
type: authorization
description: description
resources:
- attributes:
- key: serviceName
operator: stringEquals
value: kms
subjects:
- attributes:
- key: serviceName
operator: stringEquals
value: compliance
roles:
- Reader
committed: true
templateVersion:
type: ibm:IamPolicyTemplateVersion
properties:
templateId: ${policyS2sTemplate.templateId}
policy:
type: authorization
description: description
resource:
attributes:
- key: serviceName
operator: stringEquals
value: appid
subjects:
- attributes:
- key: serviceName
operator: stringEquals
value: compliance
roles:
- Reader
committed: true
policyAssignmentIamPolicyAssignment:
type: ibm:IamPolicyAssignment
properties:
version: '1.0'
target:
type: Account
id: <target-accountId>
templates:
id: ${policyS2sTemplate.templateId}
version: ${policyS2sTemplate.version}
templateVersion: ${templateVersion.version}
policyAssignmentIndex/iamPolicyAssignmentIamPolicyAssignment:
type: ibm:IamPolicyAssignment
properties:
version: '1.0'
target:
type: Account Group
id: <target-accountgroupId>
templates:
id: ${policyS2sTemplate.templateId}
version: ${policyS2sTemplate.version}
templateVersion: ${templateVersion.version}
policyAssignmentIbmIndex/iamPolicyAssignmentIamPolicyAssignment:
type: ibm:IamPolicyAssignment
properties:
version: '1.0'
target:
type: Enterprise
id: <target-enterpriseId>
templates:
id: ${policyS2sTemplate.templateId}
version: ${policyS2sTemplate.version}
templateVersion: ${templateVersion.version}
Note: Above configuration is to create policy template versions and assign to a target enterprise account. Update this parameter(template_version) and pulumi up again to update the assignment
Timeouts section
The resource includes default timeout settings for the following operations:
create
- (Timeout) Defaults to 30 minutes.update
- (Timeout) Defaults to 30 minutes.delete
- (Timeout) Defaults to 30 minutes.
Create IamPolicyAssignment Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new IamPolicyAssignment(name: string, args: IamPolicyAssignmentArgs, opts?: CustomResourceOptions);
@overload
def IamPolicyAssignment(resource_name: str,
args: IamPolicyAssignmentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def IamPolicyAssignment(resource_name: str,
opts: Optional[ResourceOptions] = None,
target: Optional[Mapping[str, str]] = None,
templates: Optional[IamPolicyAssignmentTemplatesArgs] = None,
version: Optional[str] = None,
accept_language: Optional[str] = None,
iam_policy_assignment_id: Optional[str] = None,
template_version: Optional[str] = None,
timeouts: Optional[IamPolicyAssignmentTimeoutsArgs] = None)
func NewIamPolicyAssignment(ctx *Context, name string, args IamPolicyAssignmentArgs, opts ...ResourceOption) (*IamPolicyAssignment, error)
public IamPolicyAssignment(string name, IamPolicyAssignmentArgs args, CustomResourceOptions? opts = null)
public IamPolicyAssignment(String name, IamPolicyAssignmentArgs args)
public IamPolicyAssignment(String name, IamPolicyAssignmentArgs args, CustomResourceOptions options)
type: ibm:IamPolicyAssignment
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 IamPolicyAssignmentArgs
- 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 IamPolicyAssignmentArgs
- 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 IamPolicyAssignmentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args IamPolicyAssignmentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args IamPolicyAssignmentArgs
- 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 iamPolicyAssignmentResource = new Ibm.IamPolicyAssignment("iamPolicyAssignmentResource", new()
{
Target =
{
{ "string", "string" },
},
Templates = new Ibm.Inputs.IamPolicyAssignmentTemplatesArgs
{
Id = "string",
Version = "string",
},
Version = "string",
AcceptLanguage = "string",
IamPolicyAssignmentId = "string",
TemplateVersion = "string",
Timeouts = new Ibm.Inputs.IamPolicyAssignmentTimeoutsArgs
{
Create = "string",
Delete = "string",
Update = "string",
},
});
example, err := ibm.NewIamPolicyAssignment(ctx, "iamPolicyAssignmentResource", &ibm.IamPolicyAssignmentArgs{
Target: pulumi.StringMap{
"string": pulumi.String("string"),
},
Templates: &ibm.IamPolicyAssignmentTemplatesArgs{
Id: pulumi.String("string"),
Version: pulumi.String("string"),
},
Version: pulumi.String("string"),
AcceptLanguage: pulumi.String("string"),
IamPolicyAssignmentId: pulumi.String("string"),
TemplateVersion: pulumi.String("string"),
Timeouts: &ibm.IamPolicyAssignmentTimeoutsArgs{
Create: pulumi.String("string"),
Delete: pulumi.String("string"),
Update: pulumi.String("string"),
},
})
var iamPolicyAssignmentResource = new IamPolicyAssignment("iamPolicyAssignmentResource", IamPolicyAssignmentArgs.builder()
.target(Map.of("string", "string"))
.templates(IamPolicyAssignmentTemplatesArgs.builder()
.id("string")
.version("string")
.build())
.version("string")
.acceptLanguage("string")
.iamPolicyAssignmentId("string")
.templateVersion("string")
.timeouts(IamPolicyAssignmentTimeoutsArgs.builder()
.create("string")
.delete("string")
.update("string")
.build())
.build());
iam_policy_assignment_resource = ibm.IamPolicyAssignment("iamPolicyAssignmentResource",
target={
"string": "string",
},
templates={
"id": "string",
"version": "string",
},
version="string",
accept_language="string",
iam_policy_assignment_id="string",
template_version="string",
timeouts={
"create": "string",
"delete": "string",
"update": "string",
})
const iamPolicyAssignmentResource = new ibm.IamPolicyAssignment("iamPolicyAssignmentResource", {
target: {
string: "string",
},
templates: {
id: "string",
version: "string",
},
version: "string",
acceptLanguage: "string",
iamPolicyAssignmentId: "string",
templateVersion: "string",
timeouts: {
create: "string",
"delete": "string",
update: "string",
},
});
type: ibm:IamPolicyAssignment
properties:
acceptLanguage: string
iamPolicyAssignmentId: string
target:
string: string
templateVersion: string
templates:
id: string
version: string
timeouts:
create: string
delete: string
update: string
version: string
IamPolicyAssignment 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 IamPolicyAssignment resource accepts the following input properties:
- Target Dictionary<string, string>
- assignment target account and type. Nested schema for target:
- Templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- Version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- Accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- Iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Template
Version string - The policy template version.
- Timeouts
Iam
Policy Assignment Timeouts
- Target map[string]string
- assignment target account and type. Nested schema for target:
- Templates
Iam
Policy Assignment Templates Args - The set of properties required for a policy assignment. Nested schema for templates:
- Version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- Accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- Iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Template
Version string - The policy template version.
- Timeouts
Iam
Policy Assignment Timeouts Args
- target Map<String,String>
- assignment target account and type. Nested schema for target:
- templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- version String
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language String - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- iam
Policy StringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- template
Version String - The policy template version.
- timeouts
Iam
Policy Assignment Timeouts
- target {[key: string]: string}
- assignment target account and type. Nested schema for target:
- templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- template
Version string - The policy template version.
- timeouts
Iam
Policy Assignment Timeouts
- target Mapping[str, str]
- assignment target account and type. Nested schema for target:
- templates
Iam
Policy Assignment Templates Args - The set of properties required for a policy assignment. Nested schema for templates:
- version str
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept_
language str - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- iam_
policy_ strassignment_ id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- template_
version str - The policy template version.
- timeouts
Iam
Policy Assignment Timeouts Args
- target Map<String>
- assignment target account and type. Nested schema for target:
- templates Property Map
- The set of properties required for a policy assignment. Nested schema for templates:
- version String
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language String - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- iam
Policy StringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- template
Version String - The policy template version.
- timeouts Property Map
Outputs
All input properties are implicitly available as output properties. Additionally, the IamPolicyAssignment resource produces the following output properties:
- Account
Id string - (String) The account GUID that the policies assignments belong to..
- Created
At string - (String) The UTC timestamp when the policy assignment was created.
- Created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- Href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- Id string
- The provider-assigned unique ID for this managed resource.
- Last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- Last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- Resources
List<Iam
Policy Assignment Resource> - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- Template Dictionary<string, string>
- (List) policy template details. Nested schema for template:
- Account
Id string - (String) The account GUID that the policies assignments belong to..
- Created
At string - (String) The UTC timestamp when the policy assignment was created.
- Created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- Href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- Id string
- The provider-assigned unique ID for this managed resource.
- Last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- Last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- Resources
[]Iam
Policy Assignment Resource - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- Template map[string]string
- (List) policy template details. Nested schema for template:
- account
Id String - (String) The account GUID that the policies assignments belong to..
- created
At String - (String) The UTC timestamp when the policy assignment was created.
- created
By StringId - (String) The iam ID of the entity that created the policy assignment.
- href String
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- id String
- The provider-assigned unique ID for this managed resource.
- last
Modified StringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified StringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
List<Iam
Policy Assignment Resource> - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- template Map<String,String>
- (List) policy template details. Nested schema for template:
- account
Id string - (String) The account GUID that the policies assignments belong to..
- created
At string - (String) The UTC timestamp when the policy assignment was created.
- created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- id string
- The provider-assigned unique ID for this managed resource.
- last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
Iam
Policy Assignment Resource[] - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- template {[key: string]: string}
- (List) policy template details. Nested schema for template:
- account_
id str - (String) The account GUID that the policies assignments belong to..
- created_
at str - (String) The UTC timestamp when the policy assignment was created.
- created_
by_ strid - (String) The iam ID of the entity that created the policy assignment.
- href str
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- id str
- The provider-assigned unique ID for this managed resource.
- last_
modified_ strat - (String) The UTC timestamp when the policy assignment was last modified.
- last_
modified_ strby_ id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
Sequence[Iam
Policy Assignment Resource] - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status str
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- template Mapping[str, str]
- (List) policy template details. Nested schema for template:
- account
Id String - (String) The account GUID that the policies assignments belong to..
- created
At String - (String) The UTC timestamp when the policy assignment was created.
- created
By StringId - (String) The iam ID of the entity that created the policy assignment.
- href String
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- id String
- The provider-assigned unique ID for this managed resource.
- last
Modified StringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified StringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources List<Property Map>
- (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- template Map<String>
- (List) policy template details. Nested schema for template:
Look up Existing IamPolicyAssignment Resource
Get an existing IamPolicyAssignment 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?: IamPolicyAssignmentState, opts?: CustomResourceOptions): IamPolicyAssignment
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
accept_language: Optional[str] = None,
account_id: Optional[str] = None,
created_at: Optional[str] = None,
created_by_id: Optional[str] = None,
href: Optional[str] = None,
iam_policy_assignment_id: Optional[str] = None,
last_modified_at: Optional[str] = None,
last_modified_by_id: Optional[str] = None,
resources: Optional[Sequence[IamPolicyAssignmentResourceArgs]] = None,
status: Optional[str] = None,
target: Optional[Mapping[str, str]] = None,
template: Optional[Mapping[str, str]] = None,
template_version: Optional[str] = None,
templates: Optional[IamPolicyAssignmentTemplatesArgs] = None,
timeouts: Optional[IamPolicyAssignmentTimeoutsArgs] = None,
version: Optional[str] = None) -> IamPolicyAssignment
func GetIamPolicyAssignment(ctx *Context, name string, id IDInput, state *IamPolicyAssignmentState, opts ...ResourceOption) (*IamPolicyAssignment, error)
public static IamPolicyAssignment Get(string name, Input<string> id, IamPolicyAssignmentState? state, CustomResourceOptions? opts = null)
public static IamPolicyAssignment get(String name, Output<String> id, IamPolicyAssignmentState state, CustomResourceOptions options)
resources: _: type: ibm:IamPolicyAssignment 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.
- Accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- Account
Id string - (String) The account GUID that the policies assignments belong to..
- Created
At string - (String) The UTC timestamp when the policy assignment was created.
- Created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- Href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- Iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- Last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- Resources
List<Iam
Policy Assignment Resource> - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- Target Dictionary<string, string>
- assignment target account and type. Nested schema for target:
- Template Dictionary<string, string>
- (List) policy template details. Nested schema for template:
- Template
Version string - The policy template version.
- Templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- Timeouts
Iam
Policy Assignment Timeouts - Version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- Accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- Account
Id string - (String) The account GUID that the policies assignments belong to..
- Created
At string - (String) The UTC timestamp when the policy assignment was created.
- Created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- Href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- Iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- Last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- Resources
[]Iam
Policy Assignment Resource Args - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- Target map[string]string
- assignment target account and type. Nested schema for target:
- Template map[string]string
- (List) policy template details. Nested schema for template:
- Template
Version string - The policy template version.
- Templates
Iam
Policy Assignment Templates Args - The set of properties required for a policy assignment. Nested schema for templates:
- Timeouts
Iam
Policy Assignment Timeouts Args - Version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language String - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- account
Id String - (String) The account GUID that the policies assignments belong to..
- created
At String - (String) The UTC timestamp when the policy assignment was created.
- created
By StringId - (String) The iam ID of the entity that created the policy assignment.
- href String
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- iam
Policy StringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- last
Modified StringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified StringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
List<Iam
Policy Assignment Resource> - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- target Map<String,String>
- assignment target account and type. Nested schema for target:
- template Map<String,String>
- (List) policy template details. Nested schema for template:
- template
Version String - The policy template version.
- templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- timeouts
Iam
Policy Assignment Timeouts - version String
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language string - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- account
Id string - (String) The account GUID that the policies assignments belong to..
- created
At string - (String) The UTC timestamp when the policy assignment was created.
- created
By stringId - (String) The iam ID of the entity that created the policy assignment.
- href string
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- iam
Policy stringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- last
Modified stringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified stringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
Iam
Policy Assignment Resource[] - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- target {[key: string]: string}
- assignment target account and type. Nested schema for target:
- template {[key: string]: string}
- (List) policy template details. Nested schema for template:
- template
Version string - The policy template version.
- templates
Iam
Policy Assignment Templates - The set of properties required for a policy assignment. Nested schema for templates:
- timeouts
Iam
Policy Assignment Timeouts - version string
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept_
language str - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- account_
id str - (String) The account GUID that the policies assignments belong to..
- created_
at str - (String) The UTC timestamp when the policy assignment was created.
- created_
by_ strid - (String) The iam ID of the entity that created the policy assignment.
- href str
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- iam_
policy_ strassignment_ id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- last_
modified_ strat - (String) The UTC timestamp when the policy assignment was last modified.
- last_
modified_ strby_ id - (String) The iam ID of the entity that last modified the policy assignment.
- resources
Sequence[Iam
Policy Assignment Resource Args] - (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status str
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- target Mapping[str, str]
- assignment target account and type. Nested schema for target:
- template Mapping[str, str]
- (List) policy template details. Nested schema for template:
- template_
version str - The policy template version.
- templates
Iam
Policy Assignment Templates Args - The set of properties required for a policy assignment. Nested schema for templates:
- timeouts
Iam
Policy Assignment Timeouts Args - version str
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
- accept
Language String - Language code for translations*
default
- English*de
- German (Standard)*en
- English*es
- Spanish (Spain)*fr
- French (Standard)*it
- Italian (Standard)*ja
- Japanese*ko
- Korean*pt-br
- Portuguese (Brazil)*zh-cn
- Chinese (Simplified, PRC)*zh-tw
- (Chinese, Taiwan).- Constraints: The default value is
default
. The minimum length is1
character.
- Constraints: The default value is
- account
Id String - (String) The account GUID that the policies assignments belong to..
- created
At String - (String) The UTC timestamp when the policy assignment was created.
- created
By StringId - (String) The iam ID of the entity that created the policy assignment.
- href String
- (String) The href URL that links to the policies assignments API by policy assignment ID.
- iam
Policy StringAssignment Id - (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- last
Modified StringAt - (String) The UTC timestamp when the policy assignment was last modified.
- last
Modified StringBy Id - (String) The iam ID of the entity that last modified the policy assignment.
- resources List<Property Map>
- (List) Object for each account assigned.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for resources:
- Constraints: The maximum length is
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- target Map<String>
- assignment target account and type. Nested schema for target:
- template Map<String>
- (List) policy template details. Nested schema for template:
- template
Version String - The policy template version.
- templates Property Map
- The set of properties required for a policy assignment. Nested schema for templates:
- timeouts Property Map
- version String
- specify version of response body format.
- Constraints: Allowable values are:
1.0
. The minimum length is1
character.
- Constraints: Allowable values are:
Supporting Types
IamPolicyAssignmentResource, IamPolicyAssignmentResourceArgs
- Policies
List<Iam
Policy Assignment Resource Policy> - (String) The conflicting policy id.
- Target Dictionary<string, string>
- assignment target account and type. Nested schema for target:
- Policies
[]Iam
Policy Assignment Resource Policy - (String) The conflicting policy id.
- Target map[string]string
- assignment target account and type. Nested schema for target:
- policies
List<Iam
Policy Assignment Resource Policy> - (String) The conflicting policy id.
- target Map<String,String>
- assignment target account and type. Nested schema for target:
- policies
Iam
Policy Assignment Resource Policy[] - (String) The conflicting policy id.
- target {[key: string]: string}
- assignment target account and type. Nested schema for target:
- policies
Sequence[Iam
Policy Assignment Resource Policy] - (String) The conflicting policy id.
- target Mapping[str, str]
- assignment target account and type. Nested schema for target:
- policies List<Property Map>
- (String) The conflicting policy id.
- target Map<String>
- assignment target account and type. Nested schema for target:
IamPolicyAssignmentResourcePolicy, IamPolicyAssignmentResourcePolicyArgs
- Error
Messages List<IamPolicy Assignment Resource Policy Error Message> - (List) The error response from API. Nested schema for error_message:
- Resource
Createds List<IamPolicy Assignment Resource Policy Resource Created> - (List) On success, includes the policy assigned. Nested schema for resource_created:
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- Error
Messages []IamPolicy Assignment Resource Policy Error Message - (List) The error response from API. Nested schema for error_message:
- Resource
Createds []IamPolicy Assignment Resource Policy Resource Created - (List) On success, includes the policy assigned. Nested schema for resource_created:
- Status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- error
Messages List<IamPolicy Assignment Resource Policy Error Message> - (List) The error response from API. Nested schema for error_message:
- resource
Createds List<IamPolicy Assignment Resource Policy Resource Created> - (List) On success, includes the policy assigned. Nested schema for resource_created:
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- error
Messages IamPolicy Assignment Resource Policy Error Message[] - (List) The error response from API. Nested schema for error_message:
- resource
Createds IamPolicy Assignment Resource Policy Resource Created[] - (List) On success, includes the policy assigned. Nested schema for resource_created:
- status string
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- error_
messages Sequence[IamPolicy Assignment Resource Policy Error Message] - (List) The error response from API. Nested schema for error_message:
- resource_
createds Sequence[IamPolicy Assignment Resource Policy Resource Created] - (List) On success, includes the policy assigned. Nested schema for resource_created:
- status str
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
- error
Messages List<Property Map> - (List) The error response from API. Nested schema for error_message:
- resource
Createds List<Property Map> - (List) On success, includes the policy assigned. Nested schema for resource_created:
- status String
- (String) The policy assignment status.
- Constraints: Allowable values are:
in_progress
,succeeded
,succeed_with_errors
,failed
.
- Constraints: Allowable values are:
IamPolicyAssignmentResourcePolicyErrorMessage, IamPolicyAssignmentResourcePolicyErrorMessageArgs
- Code string
- (String) error code.
- Error
Code string - Errors
List<Iam
Policy Assignment Resource Policy Error Message Error> - (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- Message string
- (String) Error message detailing the nature of the error.
- Name string
- (String) Name of the error.
errorCode
- (String) error code.
- Status
Code double - (Integer) The http error code of the response.
- Trace string
- Code string
- (String) error code.
- Error
Code string - Errors
[]Iam
Policy Assignment Resource Policy Error Message Error - (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- Message string
- (String) Error message detailing the nature of the error.
- Name string
- (String) Name of the error.
errorCode
- (String) error code.
- Status
Code float64 - (Integer) The http error code of the response.
- Trace string
- code String
- (String) error code.
- error
Code String - errors
List<Iam
Policy Assignment Resource Policy Error Message Error> - (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- message String
- (String) Error message detailing the nature of the error.
- name String
- (String) Name of the error.
errorCode
- (String) error code.
- status
Code Double - (Integer) The http error code of the response.
- trace String
- code string
- (String) error code.
- error
Code string - errors
Iam
Policy Assignment Resource Policy Error Message Error[] - (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- message string
- (String) Error message detailing the nature of the error.
- name string
- (String) Name of the error.
errorCode
- (String) error code.
- status
Code number - (Integer) The http error code of the response.
- trace string
- code str
- (String) error code.
- error_
code str - errors
Sequence[Iam
Policy Assignment Resource Policy Error Message Error] - (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- message str
- (String) Error message detailing the nature of the error.
- name str
- (String) Name of the error.
errorCode
- (String) error code.
- status_
code float - (Integer) The http error code of the response.
- trace str
- code String
- (String) error code.
- error
Code String - errors List<Property Map>
- (List) The errors encountered during the response.
- Constraints: The maximum length is
1
item. The minimum length is1
item. Nested schema for errors:
- Constraints: The maximum length is
- message String
- (String) Error message detailing the nature of the error.
- name String
- (String) Name of the error.
errorCode
- (String) error code.
- status
Code Number - (Integer) The http error code of the response.
- trace String
IamPolicyAssignmentResourcePolicyErrorMessageError, IamPolicyAssignmentResourcePolicyErrorMessageErrorArgs
- Code string
- (String) error code.
- Details
List<Iam
Policy Assignment Resource Policy Error Message Error Detail> - (List) Additional error details. Nested schema for details:
- Message string
- (String) Error message detailing the nature of the error.
- More
Info string - (String) Additional info for error.
- Code string
- (String) error code.
- Details
[]Iam
Policy Assignment Resource Policy Error Message Error Detail - (List) Additional error details. Nested schema for details:
- Message string
- (String) Error message detailing the nature of the error.
- More
Info string - (String) Additional info for error.
- code String
- (String) error code.
- details
List<Iam
Policy Assignment Resource Policy Error Message Error Detail> - (List) Additional error details. Nested schema for details:
- message String
- (String) Error message detailing the nature of the error.
- more
Info String - (String) Additional info for error.
- code string
- (String) error code.
- details
Iam
Policy Assignment Resource Policy Error Message Error Detail[] - (List) Additional error details. Nested schema for details:
- message string
- (String) Error message detailing the nature of the error.
- more
Info string - (String) Additional info for error.
- code str
- (String) error code.
- details
Sequence[Iam
Policy Assignment Resource Policy Error Message Error Detail] - (List) Additional error details. Nested schema for details:
- message str
- (String) Error message detailing the nature of the error.
- more_
info str - (String) Additional info for error.
- code String
- (String) error code.
- details List<Property Map>
- (List) Additional error details. Nested schema for details:
- message String
- (String) Error message detailing the nature of the error.
- more
Info String - (String) Additional info for error.
IamPolicyAssignmentResourcePolicyErrorMessageErrorDetail, IamPolicyAssignmentResourcePolicyErrorMessageErrorDetailArgs
- Conflicts
Withs List<IamPolicy Assignment Resource Policy Error Message Error Detail Conflicts With> - (List) Details of conflicting resource. Nested schema for conflicts_with:
- Conflicts
Withs []IamPolicy Assignment Resource Policy Error Message Error Detail Conflicts With - (List) Details of conflicting resource. Nested schema for conflicts_with:
- conflicts
Withs List<IamPolicy Assignment Resource Policy Error Message Error Detail Conflicts With> - (List) Details of conflicting resource. Nested schema for conflicts_with:
- conflicts
Withs IamPolicy Assignment Resource Policy Error Message Error Detail Conflicts With[] - (List) Details of conflicting resource. Nested schema for conflicts_with:
- conflicts_
withs Sequence[IamPolicy Assignment Resource Policy Error Message Error Detail Conflicts With] - (List) Details of conflicting resource. Nested schema for conflicts_with:
- conflicts
Withs List<Property Map> - (List) Details of conflicting resource. Nested schema for conflicts_with:
IamPolicyAssignmentResourcePolicyErrorMessageErrorDetailConflictsWith, IamPolicyAssignmentResourcePolicyErrorMessageErrorDetailConflictsWithArgs
IamPolicyAssignmentResourcePolicyResourceCreated, IamPolicyAssignmentResourcePolicyResourceCreatedArgs
- Id string
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Id string
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- id String
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- id string
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- id str
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- id String
- (String) policy template id.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
IamPolicyAssignmentTemplates, IamPolicyAssignmentTemplatesArgs
- Id string
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Version string
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
- Id string
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- Version string
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
- id String
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- version String
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
- id string
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- version string
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
- id str
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- version str
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
- id String
- ID of the template.
- Constraints: The maximum length is
51
characters. The minimum length is1
character. The value must match regular expression/^policyTemplate-[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/
.
- Constraints: The maximum length is
- version String
- template version .
- Constraints: The maximum length is
2
characters. The minimum length is1
character. The value must match regular expression/^[0-9]*$/
.
- Constraints: The maximum length is
IamPolicyAssignmentTimeouts, IamPolicyAssignmentTimeoutsArgs
Import
You can import the ibm_iam_policy_assignment
resource by using id
. Policy assignment ID.
Syntax
```sh $ pulumi import ibm:index/iamPolicyAssignment:IamPolicyAssignment policy_assignment <id> ```
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.