Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
fklasen-snyk authored Mar 22, 2024
1 parent e624085 commit 3bcd05a
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions modules/iam/main.tf
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
data "aws_iam_policy_document" "policy" {
data "aws_iam_policy_document" "terraform_data_policy" {
statement {
effect = "Allow"
actions = ["*"]
resources = ["*"]
}
}

resource "aws_iam_user" "user" {
resource "aws_iam_user" "terraform_user" {
name = "test-user"
}

resource "aws_iam_policy" "policy" {
name = "test-policy"
resource "aws_iam_policy" "terraform_policy" {
name = "test_policy"
description = "A test policy"
policy = data.aws_iam_policy_document.policy.json
policy = data.aws_iam_policy_document.terraform_data_policy.json
}

resource "aws_iam_policy_attachment" "attach" {
name = "attachment"
users = [aws_iam_user.user.name]
policy_arn = aws_iam_policy.policy.arn
resource "aws_iam_policy_attachment" "terraform_policy_attach" {
name = "policy_attachment"
users = [aws_iam_user.terraform_user.name]
policy_arn = aws_iam_policy.terraform_policy.arn
}

0 comments on commit 3bcd05a

Please sign in to comment.