Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to set role arns through terraform - vault_aws_secret_backend_role assumed_role cred type #416

Open
asksmruti opened this issue May 14, 2019 · 1 comment

Comments

@asksmruti
Copy link

Is there anyway to set the role_arn through terraform ?

Here is my piece of code, however I am unable to automate this through terraform.

resource "vault_aws_secret_backend_role" "test-assume-role" {
  backend = "aws"
  name    = "test-assume-role"
  credential_type = "assumed_role"
  role_arns = ["arn:aws:iam::xxxxxxxx:role/test-role"]
  policy_document = <<EOF
  {
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "iam:*",
      "Resource": "*"
    }
  ]
}
EOF
}

It's complaining invalid or unknown key: role_arns
I tried with policy_arns but that's valid only for iam user type. Terraform doc does not say anything specific to assume_role type, at least I did not see anything

https://www.terraform.io/docs/providers/vault/r/aws_secret_backend_role.html

@asksmruti
Copy link
Author

Following pull request is the fix for this ticket. Able to include the fix into local package and it's working as expected. Waiting for the next release with the desired fix.

#407

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant