Deploy your first Azure Databricks workspace using the Non-Private Link pattern.
terraform version)az login)# Set Databricks Account ID
export TF_VAR_databricks_account_id="<your-databricks-account-id>"
# Verify
echo $TF_VAR_databricks_account_id
cd /path/to/0-repo/databricks/adb4u/deployments/non-pl
# Copy example configuration
cp terraform.tfvars.example terraform.tfvars
# Edit with your values
vim terraform.tfvars
Required values in terraform.tfvars:
workspace_prefix = "mydb" # lowercase, max 12 chars
location = "eastus2" # Azure region
resource_group_name = "rg-databricks-prod"
databricks_account_id = "<from-step-1>"
terraform init
Expected output:
Initializing modules...
- networking in ../../modules/networking
- workspace in ../../modules/workspace
- unity_catalog in ../../modules/unity-catalog
Terraform has been successfully initialized!
terraform validate
Expected: Success! The configuration is valid.
terraform plan -out=tfplan
Review the plan carefully. You should see:
terraform apply tfplan
Duration: ~15-20 minutes
# View workspace URL
terraform output workspace_url
# View all outputs
terraform output
# Save metastore ID for future workspaces
terraform output metastore_id > metastore-id.txt
# Open workspace in browser
open $(terraform output -raw workspace_url)
In Azure Portal, check:
%pip install pandas
CREATE CATALOG test_catalogSolution: Verify format is xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx (no spaces)
Solution: Ensure you have Contributor + User Access Administrator roles
Solution: Add delegation manually:
az network vnet subnet update \
--resource-group <rg> \
--vnet-name <vnet> \
--name <subnet> \
--delegations Microsoft.Databricks/workspaces
Solution: Verify NAT Gateway is created and associated with subnets
| Resource Type | Count | Purpose |
|---|---|---|
| Resource Group | 1 | Container for all resources |
| VNet | 1 | Network isolation |
| Subnets | 2 | Public + Private for Databricks |
| NSG | 1 | Network security rules |
| NAT Gateway | 1 | Stable outbound IP |
| Public IP | 1 | For NAT Gateway |
| Databricks Workspace | 1 | Main workspace |
| Storage Accounts | 2 | Metastore + External location |
| Access Connector | 1 | Unity Catalog managed identity |
Monthly Cost: ~$58 (infrastructure only, compute is additional)
create_metastore = falseexisting_metastore_idterraform destroy
⚠️ Warning: This will delete everything including Unity Catalog data!
docs/02-AUTHENTICATION.mddocs/04-TROUBLESHOOTING.mddocs/modules/ folderNeed Help? Check the troubleshooting guide or raise an issue in the repository.