Skip to content

Instantly share code, notes, and snippets.

@raphink
Created November 26, 2017 08:08
Show Gist options
  • Save raphink/283600e7161e9c3383de393758a5b05f to your computer and use it in GitHub Desktop.
Save raphink/283600e7161e9c3383de393758a5b05f to your computer and use it in GitHub Desktop.
data "aws_iam_policy_document" "terraboard" {
statement {
sid = "ReadOnly"
actions = [
"s3:GetObject",
"s3:ListBucket",
"s3:ListBucketVersions",
"s3:GetObjectVersion",
]
resources = [
"arn:aws:s3:::my-terraform-state/*",
"arn:aws:s3:::my-terraform-state",
]
effect = "Allow"
principals {
type = "AWS"
identifiers = ["${aws_iam_user.terraboard.arn}"]
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment