Skip to content

Instantly share code, notes, and snippets.

@yotann
Last active October 20, 2016 14:49
Show Gist options
  • Save yotann/90eba113b29b3a30fa0b4aef47eff82b to your computer and use it in GitHub Desktop.
Save yotann/90eba113b29b3a30fa0b4aef47eff82b to your computer and use it in GitHub Desktop.
AWS access policy sufficient for basic usage of NixOps with EC2, S3, and IAM
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [ "s3:*" ],
"Resource": [ "arn:aws:s3:::charon-*" ]
},
{
"Effect": "Allow",
"Action": [ "iam:*" ],
"Resource": [
"arn:aws:iam::*:role/charon-*",
"arn:aws:iam::*:instance-profile/charon-*"
]
},
{
"Effect": "Allow",
"Action": [ "ec2:*" ],
"Condition": {
"StringLike": { "ec2:ResourceTag/CharonNetworkUUID": "?*" }
},
"Resource": [ "*" ]
},
{
"Effect": "Allow",
"Action": [
"ec2:CreateKeyPair",
"ec2:CreateTags",
"ec2:DeleteKeyPair",
"ec2:DescribeInstances",
"ec2:DescribeImages",
"ec2:DescribeKeyPairs",
"ec2:ImportKeyPair",
"ec2:RunInstances"
],
"Resource": [ "*" ]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment