InfuseAI / piperider

Code review for data in dbt
https://www.piperider.io/
Apache License 2.0
478 stars 23 forks source link

Enable service account impersonation to connect to BigQuery #899

Closed yu-iskw closed 10 months ago

yu-iskw commented 10 months ago

Is your feature request related to a problem? Please describe. Google Cloud provides the feature to impersonate a service account. Impersonation is useful when you want to change a user's permissions without changing your Identity and Access Management (IAM) policies.

https://cloud.google.com/iam/docs/service-account-impersonation

dbt-bigquery supports the service account impersonation of Google Cloud. This feature allows users authenticating via local OAuth to access BigQuery resources based on the permissions of a service account.

https://docs.getdbt.com/docs/core/connect-data-platform/bigquery-setup#service-account-impersonation

my-profile:
  target: dev
  outputs:
    dev:
      type: bigquery
      method: oauth
      project: abc-123
      dataset: my_dataset
      impersonate_service_account: dbt-runner@yourproject.iam.gserviceaccount.com

Describe the solution you'd like I woul lke piperider to support the feature of service account impersonation by using the inforation in profiles.yml.

Describe alternatives you've considered NA

Additional context NA

popcornylu commented 10 months ago

Thanks for your feedback.

For internal tracking. sc-32423

popcornylu commented 10 months ago

Added in v0.37.0

yu-iskw commented 10 months ago

@popcornylu Thank you for quickly supporting it!