Skip to content

Instantly share code, notes, and snippets.

@rlizzo
Created January 23, 2023 06:48
Show Gist options
  • Save rlizzo/4f36f64cf66fbe662ea6802f842b0433 to your computer and use it in GitHub Desktop.
Save rlizzo/4f36f64cf66fbe662ea6802f842b0433 to your computer and use it in GitHub Desktop.
Lightning AI BYOC IAM policy - 2023-01-23
{
"Version": "2012-10-17",
"Statement": [
{
"Action": [
"autoscaling:*",
"cloudwatch:*",
"codebuild:*",
"ec2:*",
"ecr:*",
"eks:*",
"elasticloadbalancing:*",
"events:*",
"guardduty:*",
"iam:*",
"logs:*",
"route53resolver:*",
"s3:*",
"sns:*",
"sqs:*",
"tag:GetResources",
"resource-groups:SearchResources"
],
"Effect": "Allow",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "iam:CreateServiceLinkedRole",
"Resource": "*",
"Condition": {
"StringLike": {
"iam:AWSServiceName": [
"guardduty.amazonaws.com",
"malware-protection.guardduty.amazonaws.com"
]
}
}
},
{
"Effect": "Allow",
"Action": "iam:CreateServiceLinkedRole",
"Resource": "*",
"Condition": {
"StringEquals": {
"iam:AWSServiceName": [
"autoscaling.amazonaws.com",
"ec2scheduled.amazonaws.com",
"elasticloadbalancing.amazonaws.com",
"spot.amazonaws.com",
"spotfleet.amazonaws.com",
"transitgateway.amazonaws.com"
]
}
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment