dbt Redshift IAM credentials in profiles.yaml

Viewed 588

I am new to dbt and trying to get started. I have managed to configure profiles.yml to match Redshift IAM authentication profile, but running dbt debug after, gives the following error -

 >Database Error
  Unable to get temporary Redshift cluster credentials: An error occurred (ClusterNotFound) when calling the GetClusterCredentials operation: Cluster cluster_zzz not found.

However, I am able to connect fine from within DataGrip using the exact IAM configuration.

dbt documentaion I followed - https://docs.getdbt.com/reference/warehouse-profiles/redshift-profile

profiles.yml

risk:
  target: dev
  outputs:
    dev:
      type: redshift
      method: iam
      cluster_id: cluster_zzz
      host: cluster_zzz.d4dcyl2bbxyz.eu-west-1.redshift.amazonaws.com
      user: dbuser
      iam_profile: risk
      iam_duration_seconds: 900
      autocreate: true
      port: 5439
      dbname: db_name
      schema: dbname_schema
      threads: 1
      keepalives_idle: 0

Appreciate any help as it would help me move forward evaluating the tool. Thanks!

1 Answers

I managed to find the issue. I had to set the correct region in my aws config. As we are using aws-azure-login this setting didn't matter for my day to day logins

region=eu-west-1

Looking through the implementation of the IAM feature, helped me look in the right place

Related