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

What happens when we delete the gcp roleset in vault? #92

Open
kamolhasan opened this issue Jun 17, 2020 · 1 comment
Open

What happens when we delete the gcp roleset in vault? #92

kamolhasan opened this issue Jun 17, 2020 · 1 comment

Comments

@kamolhasan
Copy link

I have a vault server running. I've enabled and configured GCP secret engine by using the vault CLI tool.

$ vault secrets enable gcp
Success! Enabled the gcp secrets engine at: gcp/sh

$ vault write gcp/config [email protected]
Success! Data written to: gcp/config

Then I've configured a roleset by using,

$ vault write gcp/roleset/my-token-roleset \
    project="my-project" \
    secret_type="access_token"  \
    token_scopes="https://www.googleapis.com/auth/cloud-platform" \
    bindings=-<<EOF
      resource "//cloudresourcemanager.googleapis.com/projects/my-project" {
        roles = ["roles/viewer"]
      }
    EOF

On creation of a roleset, the vault server creates a google service account on my-project with the given bindings.

But when I delete the roleset from vault by using,

$ vault delete gcp/roleset/my-token-roleset
Success! Data deleted (if it existed) at: gcp/roleset/my-token-roleset

the google service account is still there. Is it expected behavior? If it is, how to delete the created google service account along with the deletion of gcp roleset in vault?

@kamolhasan
Copy link
Author

@emilymye Can you please help me figure out this?

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