You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: iam-roles/cloudformation-management/README.md
+77-64Lines changed: 77 additions & 64 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,79 +1,98 @@
1
1
# CloudFormation Service Role for GenAI IDP Accelerator
2
2
3
-
This directory contains the `all-patterns-deployer-role-secure.yaml` CloudFormation template that creates a dedicated IAM service role for CloudFormation to deploy, manage and modify all GenAI IDP Accelerator patterns deployments.
3
+
This directory contains the `IDP-Cloudformation-Service-Role.yaml` CloudFormation template that creates a dedicated IAM Cloudformation service role for CloudFormation to deploy, manage and modify all GenAI IDP Accelerator patterns deployments.
4
4
5
-
## What This Role Does
5
+
## <spanstyle="color: blue;">What This Role Does</span>
6
6
7
-
The **AllPatternsDeployerRole** is a CloudFormation service role that provides the necessary permissions for AWS CloudFormation to deploy, update, and manage GenAI IDP Accelerator stacks across all patterns (Pattern 1: BDA, Pattern 2: Textract+Bedrock, Pattern 3: Textract+UDOP+Bedrock). This role can only be assumed by the CloudFormation service, not by users directly.
7
+
The **IDPAcceleratorCloudFormationServiceRole** is a CloudFormation service role that provides the necessary permissions for AWS CloudFormation to deploy, update, and manage GenAI IDP Accelerator stacks across all patterns (Pattern 1: BDA, Pattern 2: Textract+Bedrock, Pattern 3: Textract+UDOP+Bedrock). This role can only be assumed by the CloudFormation service, not by users directly.
8
8
9
9
### Key Capabilities
10
-
-**Full CloudFormation Management**: Create, update, delete IDP stacks - This IAM role (which CloudFormation assumes) gives necessary privileges to create/update/delete the stack which is helpful in development and sandbox environments. In production environments, admins can further limit these permissions to their discretion (e.g. disabling stack deletion).
10
+
-**Full CloudFormation Management**: Create, update, delete IDP stacks - This IAM service role (which CloudFormation assumes) gives necessary privileges to create/update/delete the stack which is helpful in development and sandbox environments. In production environments, admins can further limit these permissions to their discretion (e.g. disabling stack deletion).
11
+
11
12
-**All Pattern Support**: Works with Pattern 1 (BDA), Pattern 2 (Textract+Bedrock), and Pattern 3 (UDOP)
12
-
-**Comprehensive AWS Service Access**: All services required by IDP Accelerator
13
13
14
+
-**Comprehensive AWS Service Access**: Supports all services required by IDP Accelerator
14
15
15
-
## Security Features
16
16
17
-
### Region Restrictions
18
-
-**Same-Region Operations**: Only allows the role to be assumed in the region where the master/existing deployment stack already exists
19
-
-**Cross-Region Prevention**: Denies all actions outside the deployment region
20
-
-**Regional Isolation**: Ensures all operations remain within the same region as the existing IDP infrastructure
-**Administrator Note**: Administrators must add an inline IAM policy to users wanting to deploy CloudFormation stacks with this service role, allowing them to pass the `IDP-AllPatterns-Deployer-Secure` role to the CloudFormation principal:
-**Administrator Note**: This role also creates an IAM Managed Policy to allow passing the Cloudformation service role. Administrators must add the inline IAM policy to users wanting to deploy or modify CloudFormation IDP stacks with this service role, allowing them to pass the `IDPAcceleratorCloudFormationServiceRole` role to the CloudFormation principal:
21
+
22
+
```yaml
23
+
PassRolePolicy:
24
+
Type: AWS::IAM::ManagedPolicy
25
+
Properties:
26
+
ManagedPolicyName: IDP-PassRolePolicy
27
+
Description: Policy to allow passing the IDP CloudFormation service role
28
+
PolicyDocument:
29
+
Version: '2012-10-17'
30
+
Statement:
31
+
- Effect: Allow
32
+
Action:
33
+
- iam:PassRole
34
+
Resource: !GetAtt CloudFormationServiceRole.Arn
38
35
```
39
36
40
37
### Access Control
41
38
- **Account-Scoped**: Only IAM entities within the same AWS account can assume the role
42
39
43
40
44
-
## Files in this Directory
41
+
## <span style="color: blue;">Files in this Directory</span>
45
42
46
-
-`all-patterns-deployer-role-secure.yaml` - CloudFormation template for the secure IAM role
43
+
- `IDP-Cloudformation-Service-Role.yaml` - CloudFormation service role template
47
44
- `README.md`- This documentation file
48
45
- `testing-guide.md`- Testing procedures and validation steps
- AWS Administrator access or IAM permissions to create roles and policies
51
+
52
+
### Step-by-Step Deployment
53
+
54
+
1. **Navigate to CloudFormation Console**
55
+
- Open the AWS Management Console
56
+
- Go to **CloudFormation** service
57
+
- Select your preferred region
58
+
59
+
2. **Create New Stack**
60
+
- Click **"Create stack"** → **"With new resources (standard)"**
51
61
52
-
-**ExistingIDPStackName**: Name of an existing IDP stack (must start with IDP or idp). It is assumed that the administrator has deployed the first IDP solution deployment.
53
-
- Must follow CloudFormation stack naming pattern: `^[Ii][Dd][Pp][a-zA-Z0-9-]*$`
62
+
3. **Specify Template**
63
+
- Select **"Upload a template file"**
64
+
- Click **"Choose file"** and select `IDP-Cloudformation-Service-Role.yaml`
65
+
- Click **"Next"**
54
66
55
-
## Quick Start
67
+
4. **Stack Details**
68
+
- **Stack name**: Enter your stack a name
69
+
- **Parameters**: No parameters required
70
+
- Click **"Next"**
56
71
57
-
1.**Deploy the IAM Role***(Administrator Required)*:
58
-
```bash
59
-
aws cloudformation deploy \
60
-
--template-file all-patterns-deployer-role-secure.yaml \ # (Note: Ensure the template file is in your current directory or provide the full path to your template file location)
61
-
--stack-name idp-deployer-role \
62
-
--parameter-overrides ExistingIDPStackName=my-existing-idp-stack \ (the name of your existing IDP stack)
63
-
--capabilities CAPABILITY_NAMED_IAM
64
-
```
72
+
5. **Configure Stack Options**
73
+
- **Tags** (optional): Add any desired tags
74
+
- **Permissions**: Leave as default
75
+
- **Stack failure options**: Leave as default
76
+
- Click **"Next"**
65
77
66
-
2.**Deploy IDP Accelerator**:
67
-
```bash
68
-
aws cloudformation deploy \
69
-
--template-file ../../template.yaml \ (path to your template.yaml file)
70
-
--stack-name my-idp-stack \ (Name of your stack, starting with prefix IDP or idp)
71
-
--role-arn arn:aws:iam::123456789012:role/All-Patterns-Deployer-Role-Secure \ (The ARN of the idp-deployer-role provided in the Output tab of the deployed role stack)
- **Capabilities**: Check **"I acknowledge that AWS CloudFormation might create IAM resources with custom names"**
81
+
- Click **"Submit"**
75
82
76
-
## AWS Service Permissions
83
+
7. **Monitor Deployment**
84
+
- Wait for stack status to show **"CREATE_COMPLETE"**
85
+
- Check the **Events** tab for any issues
86
+
87
+
8. **Retrieve Role ARN**
88
+
- Go to the **Outputs** tab
89
+
- Copy the **CloudFormationServiceRoleArn** value for future use
90
+
91
+
### Post-Deployment
92
+
- The role is now ready to be used with `--role-arn` parameter in CloudFormation deployments via CLI or as a "an existing AWS Identity and Access Management (IAM) service role that CloudFormation can assume" from the Permissions-Optional section in the Cloudformation Console.
93
+
- Users will need `iam:PassRole` permission to use this role
94
+
95
+
## <span style="color: blue;">AWS Service Permissions</span>
77
96
78
97
The role provides comprehensive access to AWS services required by all IDP patterns:
79
98
@@ -88,6 +107,7 @@ The role provides comprehensive access to AWS services required by all IDP patte
-**Hard Limit**: All actions denied outside `us-east-1` and `us-west-2`
121
139
- **Deployment Region**: Role assumption restricted to deployment region
122
140
- **Compliance**: Helps meet data residency requirements
123
141
124
142
### Session Security
125
-
-**Short Sessions**: 1-hour maximum reduces credential exposure
126
-
-**Account Isolation**: Cannot be assumed cross-account
143
+
- **Account Isolation**: Cannot be assumed cross-account with the current trust policy
127
144
128
145
### Permission Scope
129
-
-**Broad Service Access**: Full service permissions for comprehensive IDP deployment
146
+
- **Broad Service Access**: Full service permissions for comprehensive IDP deployment services
130
147
- **No Resource Restrictions**: Allows flexibility but requires careful usage
131
148
- **Service Trust**: CloudFormation service can assume role for stack operations
132
149
- **Compliance Note**: Organizations may need to refine and make more granular the service action permissions based on their specific security compliance guidelines and least privilege requirements
0 commit comments