-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathmember-acc-cf-template.yaml
executable file
·41 lines (40 loc) · 1.34 KB
/
member-acc-cf-template.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
AWSTemplateFormatVersion: '2010-09-09'
Description: 'Required role in member accounts'
Parameters:
GetSupportInfoRoleName:
Type: String
Default: "GetSupportInfoRole"
CentralAggregatorAwsAccountId:
Type: Number
Description: "Account Id of the central aggregator AWS account."
SupportAggregatorRoleName:
Type: String
Description: "Required role in central aggregator account."
Default: "SupportAggregator"
Resources:
GetSupportInfoRole:
Type: AWS::IAM::Role
# Role assumed from support cases central aggregator account to get support case info in this account
Properties:
RoleName: !Ref GetSupportInfoRoleName
AssumeRolePolicyDocument:
Version: "2012-10-17"
Statement:
- Sid: TrustSupportAggregator
Effect: Allow
Principal:
AWS: !Sub "arn:aws:iam::${CentralAggregatorAwsAccountId}:role/${SupportAggregatorRoleName}"
Action:
- sts:AssumeRole
Path: "/"
Policies:
- PolicyName: "read-support-cases"
PolicyDocument:
Version: "2012-10-17"
Statement:
- Effect: "Allow"
Action:
- "support:Describe*"
- "support:"
# support: is necessary for programmatic support API
Resource: "*"