cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
cancel
Showing results for 
Search instead for 
Did you mean: 

authentication is not configured for provider

164079
Contributor II

Hi team,

I started getting this message lately when trying add some new config or change my workspace with terraform :

Error: cannot create global init script: authentication is not configured for provider. Please check https://registry.terraform.io/providers/databricks/databricks/latest/docs#authentication for details

on the TF code all ok and as below:

image Im using TF version terraform-1.0.11

What could have been change?

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions

Vivian_Wilfred
Honored Contributor
Honored Contributor

Hi @Avi Edri​ looks like you are using a provider that is authenticated to the Accounts console (https://accounts.cloud.databricks.com) to create a global init script within the workspace. Can you try authentication with host and PAT token? Follow this doc

The host will be your workspace URL.

Use two providers, one with username-password auth and one with host-PAT auth for Account level management and workspace-level management respectively.

Let me know if this answers your question.

View solution in original post

4 REPLIES 4

Pat
Honored Contributor III

Hi @Avi Edri​ ,

can you please provide more details, where you are getting this error?

one option is that, you have setup .databrickscfg with the [DEFAULT] profile.

or

maybe you are not using alias while creating resource?

resource "databricks_grants" "this" {
  provider = databricks.workspace
...
}

where this error is thrown exactly?

provider "databricks" looks ok to me

164079
Contributor II

Hi Pat,

Since i have 2 workspaces on my account ( dev and prod ) , i suspect im missing some specific configuration.

I checked and no .databrickscfg file i have on my mac.

In general im trying to add another databricks instance profile via TF.

Thanks

Vivian_Wilfred
Honored Contributor
Honored Contributor

Hi @Avi Edri​ looks like you are using a provider that is authenticated to the Accounts console (https://accounts.cloud.databricks.com) to create a global init script within the workspace. Can you try authentication with host and PAT token? Follow this doc

The host will be your workspace URL.

Use two providers, one with username-password auth and one with host-PAT auth for Account level management and workspace-level management respectively.

Let me know if this answers your question.

Thank you @Vivian Wilfred​ 

yes it is working now

Welcome to Databricks Community: Lets learn, network and celebrate together

Join our fast-growing data practitioner and expert community of 80K+ members, ready to discover, help and collaborate together while making meaningful connections. 

Click here to register and join today! 

Engage in exciting technical discussions, join a group with your peers and meet our Featured Members.