@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:39.755Z") @Stability(value=Stable) public interface FromRoleArnOptions extends software.amazon.jsii.JsiiSerializable
Role.fromRoleArn.
Example:
IRole role = Role.fromRoleArn(this, "Role", "arn:aws:iam::123456789012:role/MyExistingRole", FromRoleArnOptions.builder()
// Set 'mutable' to 'false' to use the role as-is and prevent adding new
// policies to it. The default is 'true', which means the role may be
// modified as part of the deployment.
.mutable(false)
.build());
| Modifier and Type | Interface and Description |
|---|---|
static class |
FromRoleArnOptions.Builder
A builder for
FromRoleArnOptions |
static class |
FromRoleArnOptions.Jsii$Proxy
An implementation for
FromRoleArnOptions |
| Modifier and Type | Method and Description |
|---|---|
static FromRoleArnOptions.Builder |
builder() |
default Boolean |
getAddGrantsToResources()
For immutable roles: add grants to resources instead of dropping them.
|
default String |
getDefaultPolicyName()
Any policies created by this role will use this value as their ID, if specified.
|
default Boolean |
getMutable()
Whether the imported role can be modified by attaching policy resources to it.
|
@Stability(value=Stable) @Nullable default Boolean getAddGrantsToResources()
If this is false or not specified, grant permissions added to this role are ignored.
It is your own responsibility to make sure the role has the required permissions.
If this is true, any grant permissions will be added to the resource instead.
Default: false
@Stability(value=Stable) @Nullable default String getDefaultPolicyName()
Specify this if importing the same role in multiple stacks, and granting it different permissions in at least two stacks. If this is not specified (or if the same name is specified in more than one stack), a CloudFormation issue will result in the policy created in whichever stack is deployed last overwriting the policies created by the others.
Default: 'Policy'
@Stability(value=Stable) @Nullable default Boolean getMutable()
Default: true
@Stability(value=Stable) static FromRoleArnOptions.Builder builder()
FromRoleArnOptions.Builder of FromRoleArnOptionsCopyright © 2022. All rights reserved.