cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

Unity through terraform

saurabh12521
New Contributor II

I am working on automation of Unity through terraform. I have referred below link link to get started :

https://registry.terraform.io/providers/databricks/databricks/latest/docs/guides/unity-catalog-azure

I am facing issue when I create metastore using terraform :

esource "databricks_metastore" "this" {

name = "primary"

storage_root = format("abfss://%s@%s.dfs.core.windows.net/",

azurerm_storage_container.unity_catalog.name,

azurerm_storage_account.unity_catalog.name)

force_destroy = true

}

resource "databricks_metastore_data_access" "first" {

metastore_id = databricks_metastore.this.id

name = "the-keys"

azure_managed_identity {

access_connector_id = azapi_resource.access_connector.id

}

is_default = true

}

resource "databricks_metastore_assignment" "this" {

workspace_id = local.databricks_workspace_id

metastore_id = databricks_metastore.this.id

default_catalog_name = "hive_metastore"

}

##################################

Please find error as below :

imageI have also tried changing provider to databricks/databricks. still same problem.

Please help us to resolve this

3 REPLIES 3

jab-in-sf
New Contributor II

The variation I saw with this, on AWS, was this:

"You will remember that there are two ways to specify the provider= part of this. One provider config binds to account.cloud.databricks.com and the other binds to your-company-and-workspace.cloud.databricks.com. The second example has a "host" parameter to fill in, a mandatory parameter. You're using one config when it wants the other one. In this case, you're using the first type and it wants the second type."

Anonymous
Not applicable

Hi @saurabh pandey​ 

Hope all is well! Just wanted to check in if you were able to resolve your issue and would you be happy to share the solution or mark an answer as best? Else please let us know if you need more help. 

We'd love to hear from you.

Thanks!

Pat
Honored Contributor III

Not sure if you got this working, but I noticed you are using provider: `databrickslabs/databricks`, hence why this is not avaialable. You should be using new provider: `databricks/databricks`: https://registry.terraform.io/providers/databricks/databricks/latest/docs

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group