Skip to content

Commit 33fa341

Browse files
committed
ci: add AWS policy for CI/CD tool integration and X-Ray tracing permission
- Add AWS policy for CI/CD tool integration and X-Ray tracing permission - Add permissions for X-Ray actions in the new policy Signed-off-by: Bo-Yi.Wu <appleboy.tw@gmail.com>
1 parent a2bdfc0 commit 33fa341

1 file changed

Lines changed: 14 additions & 1 deletion

File tree

‎README.md‎

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ steps:
141141
142142
## AWS Policy
143143
144-
Add the following AWS policy if you want to integrate with CI/CD tools like Jenkins, GitLab Ci or Drone.
144+
Add the following AWS policy if you want to integrate with CI/CD tools like Jenkins, GitLab Ci or Drone. Your function needs permission to upload trace data to [X-Ray](https://docs.aws.amazon.com/lambda/latest/dg/services-xray.html). When you activate tracing in the Lambda console, Lambda adds the required permissions to your function's execution role. Otherwise, add the [AWSXRayDaemonWriteAccess](https://console.aws.amazon.com/iam/home#/policies/arn:aws:iam::aws:policy/AWSXRayDaemonWriteAccess) policy to the execution role.
145145
146146
```json
147147
{
@@ -156,6 +156,19 @@ Add the following AWS policy if you want to integrate with CI/CD tools like Jenk
156156
"lambda:CreateFunction"
157157
],
158158
"Resource": "arn:aws:logs:*:*:*"
159+
},
160+
{
161+
"Effect": "Allow",
162+
"Action": [
163+
"xray:PutTraceSegments",
164+
"xray:PutTelemetryRecords",
165+
"xray:GetSamplingRules",
166+
"xray:GetSamplingTargets",
167+
"xray:GetSamplingStatisticSummaries"
168+
],
169+
"Resource": [
170+
"*"
171+
]
159172
}
160173
]
161174
}

0 commit comments

Comments
 (0)
⌂ 换网址