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

vault_aws_secret_backend_role fails on a role ARN #73

Open
jasonmcintosh opened this issue Feb 14, 2018 · 7 comments
Open

vault_aws_secret_backend_role fails on a role ARN #73

jasonmcintosh opened this issue Feb 14, 2018 · 7 comments
Labels

Comments

@jasonmcintosh
Copy link

URL: PUT https://myvault/v1/aws/roles/deploy
Code: 500. Errors:

  • 1 error occurred:
  • Either policy or arn must be provided

Vault version v0.9.3

@jasonmcintosh
Copy link
Author

resource "vault_aws_secret_backend_role" "role" {
  backend = "aws"
  name    = "deploy"
  arn     = "${aws_iam_role.myrole.arn}"
}

@nickwales
Copy link

The documentation asks for policy_arn, but that doesn't work either e.g.

resource "vault_aws_secret_backend_role" "role" {
  backend     = "aws"
  name          = "deploy"
  policy_arn  = "${aws_iam_role.myrole.arn}"
}

FWIW, policy does work e.g.

resource "vault_aws_secret_backend_role" "role" {
  backend     = "aws"
  name          = "deploy"
  policy = <<EOT
{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "iam:*",
      "Resource": "*"
    }
  ]
}
EOT

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

@joelthompson
Copy link
Contributor

Heads up that I'm working on redoing some of this. I'm discussing the new behavior in hashicorp/vault#4229 and have it maybe 60% code complete.

@jasonmcintosh
Copy link
Author

Note, just hit this again... the backend doesn't support the API methods vault does:
https://www.vaultproject.io/docs/secrets/aws/index.html#sts-assumerole

@cvbarros
Copy link
Contributor

I resolution to this is via #259

@whume
Copy link

whume commented Feb 9, 2019

@cvbarros Hello, I am running into this issue as well. Is there goign to be a resolution soon? Would be great to get role_arns added via terraform. Thanks!

@zxpower
Copy link

zxpower commented Aug 17, 2020

Issue is still valid...

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

No branches or pull requests

7 participants