-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathserverless-dev-iam.sample.json
117 lines (117 loc) · 3.28 KB
/
serverless-dev-iam.sample.json
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": ["cloudformation:List*", "cloudformation:Get*", "cloudformation:ValidateTemplate"],
"Resource": ["*"]
},
{
"Effect": "Allow",
"Action": [
"cloudformation:CreateStack",
"cloudformation:CreateUploadBucket",
"cloudformation:DeleteStack",
"cloudformation:Describe*",
"cloudformation:UpdateStack"
],
"Resource": [
"arn:aws:cloudformation:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:stack/t1-ct-dev/*"
]
},
{
"Effect": "Allow",
"Action": ["lambda:Get*", "lambda:List*", "lambda:CreateFunction"],
"Resource": ["*"]
},
{
"Effect": "Allow",
"Action": [
"s3:GetBucketLocation",
"s3:CreateBucket",
"s3:DeleteBucket",
"s3:ListBucket",
"s3:GetBucketPolicy",
"s3:PutBucketPolicy",
"s3:ListBucketVersions",
"s3:PutAccelerateConfiguration",
"s3:GetEncryptionConfiguration",
"s3:PutEncryptionConfiguration",
"s3:DeleteBucketPolicy"
],
"Resource": ["arn:aws:s3:::t1-ct*serverlessdeploy*"]
},
{
"Effect": "Allow",
"Action": ["s3:PutObject", "s3:GetObject", "s3:DeleteObject"],
"Resource": ["arn:aws:s3:::t1-ct*serverlessdeploy*"]
},
{
"Effect": "Allow",
"Action": [
"lambda:AddPermission",
"lambda:CreateAlias",
"lambda:DeleteFunction",
"lambda:InvokeFunction",
"lambda:PublishVersion",
"lambda:RemovePermission",
"lambda:Update*"
],
"Resource": [
"arn:aws:lambda:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:function:t1-ct-dev-*"
]
},
{
"Effect": "Allow",
"Action": ["cloudwatch:GetMetricStatistics"],
"Resource": ["*"]
},
{
"Action": ["logs:CreateLogGroup", "logs:CreateLogStream", "logs:DeleteLogGroup"],
"Resource": ["arn:aws:logs:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:*"],
"Effect": "Allow"
},
{
"Action": ["logs:PutLogEvents"],
"Resource": ["arn:aws:logs:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:*"],
"Effect": "Allow"
},
{
"Effect": "Allow",
"Action": ["logs:DescribeLogStreams", "logs:DescribeLogGroups", "logs:FilterLogEvents"],
"Resource": ["*"]
},
{
"Effect": "Allow",
"Action": ["events:Put*", "events:Remove*", "events:Delete*"],
"Resource": [
"arn:aws:events:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:rule/t1-ct-dev-eu-central-1"
]
},
{
"Effect": "Allow",
"Action": ["events:DescribeRule"],
"Resource": [
"arn:aws:events:eu-central-1:__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:rule/t1-ct-dev-*"
]
},
{
"Effect": "Allow",
"Action": ["iam:PassRole"],
"Resource": ["arn:aws:iam::__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:role/*"]
},
{
"Effect": "Allow",
"Action": [
"iam:GetRole",
"iam:CreateRole",
"iam:PutRolePolicy",
"iam:DeleteRolePolicy",
"iam:DeleteRole"
],
"Resource": [
"arn:aws:iam::__REPLACE_WITH_YOUR_AWS_ACCOUNT_ID__:role/t1-ct-dev-eu-central-1-lambdaRole"
]
}
]
}