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

Deploy data_catalog resources with user credentials #8611

Open
dsbrambila opened this issue Mar 4, 2021 · 2 comments
Open

Deploy data_catalog resources with user credentials #8611

dsbrambila opened this issue Mar 4, 2021 · 2 comments

Comments

@dsbrambila
Copy link

dsbrambila commented Mar 4, 2021

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment. If the issue is assigned to the "modular-magician" user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If the issue is assigned to a user, that user is claiming responsibility for the issue. If the issue is assigned to "hashibot", a community member has claimed the issue already.

Description

Resources within google_data_catalog* can only be deployed if the user is logged in via a service account. Security wise this is not an ideal behavior, since it implies saving the service account credentials in the local-machine. Ideally, users should be able to deploy using only the users credentials, which has more security layers in it, e.g., 2FA.

Error message when trying to deploy data catalog resources using user credentials

Error: Error when reading or editing DataCatalogEntryGroup "projects/xx/locations/region/entryGroups/entry-group": googleapi: Error 403: Your application has authenticated using end user credentials from the Google Cloud SDK or Google Cloud Shell which are not supported by the datacatalog.googleapis.com. We recommend configuring the billing/quota_project setting in gcloud or using a service account through the auth/impersonate_service_account setting. For more information about service accounts and how to use them in your application, see https://cloud.google.com/docs/authentication/

Note: I am able to deploy data catalog resources using my user-credentials via gcloud.

New or Affected Resource(s)

  • google_data_catalog_entry
  • google_data_catalog_entry_group
  • google_data_catalog_entry_group_iam
  • google_data_catalog_policy_tag
  • google_data_catalog_policy_tag_iam
  • google_data_catalog_tag
  • google_data_catalog_tag_template
  • google_data_catalog_taxonomy
  • google_data_catalog_taxonomy_iam

References

*#8600

b/359623036

@ghost ghost added the enhancement label Mar 4, 2021
@rileykarson
Copy link
Collaborator

Have you tried https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/provider_reference#user_project_override? That makes user credentials compatible with most APIs.

You'll probably want to file an issue with the service here- the restriction comes from the API itself and adding the ability to configure the quota project is the best solution we've got clientside.

@RuggieroSanto-Reply
Copy link

Have you tried https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/provider_reference#user_project_override? That makes user credentials compatible with most APIs.

You'll probably want to file an issue with the service here- the restriction comes from the API itself and adding the ability to configure the quota project is the best solution we've got clientside.

It worked for me.

modular-magician added a commit to modular-magician/terraform-provider-google that referenced this issue Aug 15, 2023
…hashicorp#8611)

* add google_bigquery_table to version 5 upgrade doc for hashicorp#8460

* update wording

---------

Co-authored-by: Stephen Lewis (Burrows) <[email protected]>
Signed-off-by: Modular Magician <[email protected]>
modular-magician added a commit that referenced this issue Aug 15, 2023
…15509)

* add google_bigquery_table to version 5 upgrade doc for #8460

* update wording

---------

Signed-off-by: Modular Magician <[email protected]>
Co-authored-by: Stephen Lewis (Burrows) <[email protected]>
@github-actions github-actions bot added forward/review In review; remove label to forward service/datacatalog labels Aug 17, 2023
@ggtisc ggtisc added waiting-response and removed forward/review In review; remove label to forward labels Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants