Integrating Terraform and Azure DevOps to manage Azure Databricks

Published May 02 2022 09:31 AM 1,339 Views
Microsoft

Continuous integration and continuous delivery (CI/CD) culture started to get popular, and it brought the challenge of having everything automatized, aiming to make processes easier and maintainable for everyone.

 

One of the most valuable aspects of CI/CD is the integration of the Infrastructure as Code (IaC) concept, with IaC we can version our infrastructure, save money, creating new environments in minutes, among many more benefits. I won't go deeper about IaC, but if you want to learn further visit: The benefits of Infrastructure as Code 

 

IaC can also bring some challenges when creating resources needed for the projects. This is mostly due to creating all the scripts for the infrastructure is a task that is usually assigned to the infrastructure engineers, and it happens that we can't have the opportunity to be helped for any reason.

 

As a Data Engineer, I would like to help you understand the CI/CD process with a hands-on. You'll learn how to create Azure Databricks through Terraform and Azure DevOps, whether you are creating projects by yourself or supporting your Infrastructure Team.

 

In this article, you´ll learn how to integrate Azure Databricks with Terraform and Azure DevOps and the main reason is just because in this moment I've had some difficulties getting the information with these 3 technologies together.

 

First of all, you'll need some prerequisites 

 

  • Azure Subscription
  • Azure Resource Group (you can use an existing one)
  • Azure DevOps account
  • Azure Storage Account with a container named "tfstate"
  • Visual Studio Code (it's up to you)

So, let's start and have some fun

 

Please, go ahead and download or clone this GitHub repository  databrick-tf-ado and get demo-start branch.

In the folder you'll see a file named main.tf and 2 more files in the folder modules/databricks-workspace

 

Vanessa_Segovia_0-1651505246300.png

 

It should be noted that this example is a basic one, so you can find more information of all the features for databricks in this link: https://registry.terraform.io/providers/databrickslabs/databricks/latest/docs 

 

Now, go to the main.tf file in the root folder and find line 8 where the declaration of azurerm starts

 

 

 

  backend "azurerm" {
    resource_group_name  = "demodb-rg"
    storage_account_name = "demodbtfstate"
    container_name       = "tfstate"
    key                  = "dev.terraform.tfstate"
  }

 

 

 

there you need to change the value of resource_group_name and storage_account_name for the values of you subscription, you can find those values in your Azure Portal, they need to be already created.

 

storageaccount.png

 

 

In main.tf file inside root folder there's a reference to a module called "databricks-workspace", now in that folder you can see 2 more files main.tf and variables.tf. 

 

main.tf contains the definition to create a databricks workspace, a cluster, a scope, a secret and a notebook, in the format that terraform requires and variables.tf contains the information of the values that could change depending on the environment. 

 

Now that you changed the values mentioned above into a GitHub or DevOps repository if you need assistance for that visit these pages: GitHub or DevOps.

 

At this moment we have our github or devops repository with the names that we require configured, so let´s create our pipeline to deploy our databricks environment into our Azure subscription.

 

First go to your azure subscription and check that you don't have a databricks called demodb-workspace

 

portalazurebefore.png

 

 

You'll need to install an extension so DevOps can use terraform commands so go to Terraform Extension.

 

Once is installed in your project in Azure DevOps click on Pipelines-Release and Create "new pipeline", it appears the option by creating the pipeline with YAML or with the Editor, I'll choose the Editor so we can see it clearer.

 

Vanessa_Segovia_3-1651505246308.png

 

 

In Add an Artifact in the Artifact section of the pipeline select your source type (provider where you uploaded your repository) and fill all the required information, like the image below and click "Add"

 

addartifact.png

 

 

Then click on Add stage in Stages section and choose empty Job and name the stage as "DEV"

 

addstage.png

 

After that click on Jobs below the name of the stage

Vanessa_Segovia_6-1651505246314.png

 

In the Agent job, press the "+" button and search for "terraform" select "Terraform tool installer"

 

addinstallterraform.png

Leave the default information

 

Then Add another 3 tasks of "Terraform" task

 

addterraformtask.png

 

Name the second task after Installer as "Init" and fill the information required like the image:

 

init.png

 

 

For all these 3 tasks set the information of your subscription, resource group, storage account and container, and there's also a value labeled key, there you have to set "dev.terraform.tfstate" is a key that terraform uses to keep tracking of your Infrastructure changes.

 

suscription.png

 

Name next task as "Plan"

 

plan.png

 

Next task "Apply"

 

apply.png

 

Now change the name of your pipeline and save it

 

namepipeline.png

 

And we only need to create a Release to test it

 

You can monitor the progress

 

progress.png

 

 

When it finished, if everything was good you'll see your pipeline as successful 

 

success.png

 

Lastly let´s confirm in the azure portal that everything is created correctly

 

finalportal.png

Then login into your workspace so you can check that the cluster, the scope, the secret, and the notebook are created and working correctly.

 

workspace.png

 

 

With that you can easily maintain your environments safe from the changes that contributors can do, only one way to accept modifications into your infrastructure.

 

Let us know any comments or questions.

 

 

 

 

 

 

 

 

%3CLINGO-SUB%20id%3D%22lingo-sub-3295414%22%20slang%3D%22en-US%22%3EIntegrating%20Terraform%20and%20Azure%20DevOps%20to%20manage%20Azure%20Databricks%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3295414%22%20slang%3D%22en-US%22%3E%3CP%3EContinuous%20integration%20and%20continuous%20delivery%20(CI%2FCD)%20culture%20started%20to%20get%20popular%2C%20and%20it%20brought%20the%20challenge%20of%20having%20everything%20automatized%2C%20aiming%20to%20make%20processes%20easier%20and%20maintainable%20for%20everyone.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EOne%20of%20the%20most%20valuable%20aspects%20of%20CI%2FCD%20is%20the%20integration%20of%20the%20Infrastructure%20as%20Code%20(IaC)%20concept%2C%20with%20IaC%20we%20can%20version%20our%20infrastructure%2C%20save%20money%2C%20creating%20new%20environments%20in%20minutes%2C%20among%20many%20more%20benefits.%20I%20won't%20go%20deeper%20about%20IaC%2C%20but%20if%20you%20want%20to%20learn%20further%20visit%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Ffasttrack-for-azure%2Fthe-benefits-of-infrastructure-as-code%2Fba-p%2F2069350%22%20target%3D%22_blank%22%3EThe%20benefits%20of%20Infrastructure%20as%20Code%26nbsp%3B%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIaC%20can%20also%20bring%20some%20challenges%20when%20creating%20resources%20needed%20for%20the%20projects.%20This%20is%20mostly%20due%20to%20creating%20all%20the%20scripts%20for%20the%20infrastructure%20is%20a%20task%20that%20is%20usually%20assigned%20to%20the%20infrastructure%20engineers%2C%20and%20it%20happens%20that%20we%20can't%20have%20the%20opportunity%20to%20be%20helped%20for%20any%20reason.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAs%20a%20Data%20Engineer%2C%20I%20would%20like%20to%20help%20you%20understand%20the%20CI%2FCD%20process%20with%20a%20hands-on.%20You'll%20learn%20how%20to%20create%20Azure%20Databricks%20through%20Terraform%20and%20Azure%20DevOps%2C%20whether%20you%20are%20creating%20projects%20by%20yourself%20or%20supporting%20your%20Infrastructure%20Team.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20this%20article%2C%20you%C2%B4ll%20learn%20how%20to%20integrate%20Azure%20Databricks%20with%20Terraform%20and%20Azure%20DevOps%20and%20the%20main%20reason%20is%20just%20because%20in%20this%20moment%20I've%20had%20some%20difficulties%20getting%20the%20information%20with%20these%203%20technologies%20together.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFirst%20of%20all%2C%20you'll%20need%20some%20prerequisites%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EAzure%20Subscription%3C%2FLI%3E%0A%3CLI%3EAzure%20Resource%20Group%20(you%20can%20use%20an%20existing%20one)%3C%2FLI%3E%0A%3CLI%3EAzure%20DevOps%20account%3C%2FLI%3E%0A%3CLI%3EAzure%20Storage%20Account%26nbsp%3Bwith%20a%20container%20named%20%22tfstate%22%3C%2FLI%3E%0A%3CLI%3EVisual%20Studio%20Code%20(it's%20up%20to%20you)%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3ESo%2C%20let's%20start%20and%20have%20some%20fun%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EPlease%2C%20go%20ahead%20and%20download%20or%20clone%20this%20GitHub%20repository%26nbsp%3B%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fvasegovi%2Fdatabrick-tf-ado%2Ftree%2Fdemo-start%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Edatabrick-tf-ado%3C%2FA%3E%26nbsp%3Band%20get%26nbsp%3Bdemo-start%20branch.%3C%2FP%3E%0A%3CP%3EIn%20the%20folder%20you'll%20see%20a%20file%20named%26nbsp%3B%3CEM%3Emain.tf%3C%2FEM%3E%26nbsp%3Band%202%20more%20files%20in%20the%20folder%26nbsp%3B%3CEM%3Emodules%2Fdatabricks-workspace%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Vanessa_Segovia_0-1651505246300.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368457iE02804F81AE4DC82%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Vanessa_Segovia_0-1651505246300.png%22%20alt%3D%22Vanessa_Segovia_0-1651505246300.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIt%20should%20be%20noted%20that%20this%20example%20is%20a%20basic%20one%2C%20so%20you%20can%20find%20more%20information%20of%20all%20the%20features%20for%20databricks%20in%20this%20link%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fregistry.terraform.io%2Fproviders%2Fdatabrickslabs%2Fdatabricks%2Flatest%2Fdocs%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3Ehttps%3A%2F%2Fregistry.terraform.io%2Fproviders%2Fdatabrickslabs%2Fdatabricks%2Flatest%2Fdocs%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENow%2C%20go%20to%20the%20main.tf%20file%20in%20the%20root%20folder%20and%20find%20line%208%20where%20the%20declaration%20of%20azurerm%20starts%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-json%22%3E%3CCODE%3E%20%20backend%20%22azurerm%22%20%7B%0A%20%20%20%20resource_group_name%20%20%3D%20%22demodb-rg%22%0A%20%20%20%20storage_account_name%20%3D%20%22demodbtfstate%22%0A%20%20%20%20container_name%20%20%20%20%20%20%20%3D%20%22tfstate%22%0A%20%20%20%20key%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%3D%20%22dev.terraform.tfstate%22%0A%20%20%7D%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Ethere%20you%20need%20to%20change%20the%20value%20of%20resource_group_name%20and%20storage_account_name%20for%20the%20values%20of%20you%20subscription%2C%20you%20can%20find%20those%20values%20in%20your%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fms.portal.azure.com%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EAzure%20Portal%3C%2FA%3E%2C%20they%20need%20to%20be%20already%20created.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22storageaccount.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368493iDD992E074D8A017F%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22storageaccount.png%22%20alt%3D%22storageaccount.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20main.tf%20file%20inside%20root%20folder%20there's%20a%20reference%20to%20a%20module%20called%26nbsp%3B%3CEM%3E%22databricks-workspace%22%2C%26nbsp%3B%3C%2FEM%3Enow%20in%20that%20folder%20you%20can%20see%202%20more%20files%20main.tf%20and%20variables.tf.%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Emain.tf%20contains%20the%20definition%20to%20create%20a%20databricks%20workspace%2C%20a%20cluster%2C%20a%20scope%2C%20a%20secret%20and%20a%20notebook%2C%20in%20the%20format%20that%20terraform%20requires%20and%20variables.tf%20contains%20the%20information%20of%20the%20values%20that%20could%20change%20depending%20on%20the%20environment.%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENow%20that%20you%20changed%20the%20values%20mentioned%20above%20into%20a%20GitHub%20or%20DevOps%20repository%20if%20you%20need%20assistance%20for%20that%20visit%20these%20pages%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.github.com%2Fen%2Fget-started%2Fimporting-your-projects-to-github%2Fimporting-source-code-to-github%2Fadding-locally-hosted-code-to-github%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EGitHub%3C%2FA%3E%26nbsp%3Bor%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fdevops%2Frepos%2Fgit%2Fshare-your-code-in-git-cmdline%3Fview%3Dazure-devops%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EDevOps.%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAt%20this%20moment%20we%20have%20our%20github%20or%20devops%20repository%20with%20the%20names%20that%20we%20require%20configured%2C%20so%20let%C2%B4s%20create%20our%20pipeline%20to%20deploy%20our%20databricks%20environment%20into%20our%20Azure%20subscription.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFirst%20go%20to%20your%20azure%20subscription%20and%20check%20that%20you%20don't%20have%20a%20databricks%20called%20demodb-workspace%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22portalazurebefore.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368496i3FCD81B0CB0485AC%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22portalazurebefore.png%22%20alt%3D%22portalazurebefore.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou'll%20need%20to%20install%20an%20extension%20so%20DevOps%20can%20use%20terraform%20commands%20so%20go%20to%3CA%20href%3D%22https%3A%2F%2Fmarketplace.visualstudio.com%2Fitems%3FitemName%3Dms-devlabs.custom-terraform-tasks%26amp%3BtargetId%3Da7db2653-9cd1-403c-830e-3045ddb3cdb2%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3E%26nbsp%3BTerraform%20Extension.%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EOnce%20is%20installed%20in%20your%20project%20in%20Azure%20DevOps%20click%20on%20Pipelines-Release%20and%20Create%20%22new%20pipeline%22%2C%20it%20appears%20the%20option%20by%20creating%20the%20pipeline%20with%20YAML%20or%20with%20the%20Editor%2C%20I'll%20choose%20the%20Editor%20so%20we%20can%20see%20it%20clearer.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Vanessa_Segovia_3-1651505246308.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368459iA223DCD9319F5F70%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Vanessa_Segovia_3-1651505246308.png%22%20alt%3D%22Vanessa_Segovia_3-1651505246308.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20Add%20an%20Artifact%20in%20the%20Artifact%20section%20of%20the%20pipeline%20select%20your%20source%20type%20(provider%20where%20you%20uploaded%20your%20repository)%20and%20fill%20all%20the%20required%20information%2C%20like%20the%20image%20below%20and%20click%20%22Add%22%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22addartifact.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368497i291B5182D38E8539%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22addartifact.png%22%20alt%3D%22addartifact.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThen%20click%20on%20Add%20stage%20in%20Stages%20section%20and%20choose%20empty%20Job%20and%20name%20the%20stage%20as%20%22DEV%22%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22addstage.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368498iD92A4DE0709B0E81%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22addstage.png%22%20alt%3D%22addstage.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAfter%20that%20click%20on%20Jobs%20below%20the%20name%20of%20the%20stage%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Vanessa_Segovia_6-1651505246314.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368464i5CC0CFECDF3B936F%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Vanessa_Segovia_6-1651505246314.png%22%20alt%3D%22Vanessa_Segovia_6-1651505246314.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20the%20Agent%20job%2C%20press%20the%20%22%2B%22%20button%20and%20search%20for%20%22terraform%22%20select%20%22Terraform%20tool%20installer%22%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22addinstallterraform.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368501iA4E5A5DE34D704C7%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22addinstallterraform.png%22%20alt%3D%22addinstallterraform.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3ELeave%20the%20default%20information%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThen%20Add%20another%203%20tasks%20of%20%22Terraform%22%20task%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22addterraformtask.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368502i2557544422BBE26A%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22addterraformtask.png%22%20alt%3D%22addterraformtask.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EName%20the%20second%20task%20after%20Installer%20as%20%22Init%22%20and%20fill%20the%20information%20required%20like%20the%20image%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22init.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368503iBDC27BC1408163CE%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22init.png%22%20alt%3D%22init.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFor%20all%20these%203%20tasks%20set%20the%20information%20of%20your%20subscription%2C%20resource%20group%2C%20storage%20account%20and%20container%2C%20and%20there's%20also%20a%20value%20labeled%20key%2C%20there%20you%20have%20to%20set%20%22dev.terraform.tfstate%22%20is%20a%20key%20that%20terraform%20uses%20to%20keep%20tracking%20of%20your%20Infrastructure%20changes.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22suscription.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368504i56D9741CAE977C56%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22suscription.png%22%20alt%3D%22suscription.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EName%20next%20task%20as%20%22Plan%22%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22plan.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368505i9FFAF2967674BACB%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22plan.png%22%20alt%3D%22plan.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENext%20task%20%22Apply%22%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22apply.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368507i054E286676D24890%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22apply.png%22%20alt%3D%22apply.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENow%20change%20the%20name%20of%20your%20pipeline%20and%20save%20it%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22namepipeline.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368508i02DD2A32E2139A88%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22namepipeline.png%22%20alt%3D%22namepipeline.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAnd%20we%20only%20need%20to%20create%20a%20Release%20to%20test%20it%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20can%20monitor%20the%20progress%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22progress.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368509i4A0C7A674C2F89C0%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22progress.png%22%20alt%3D%22progress.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhen%20it%20finished%2C%20if%20everything%20was%20good%20you'll%20see%20your%20pipeline%20as%20successful%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22success.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368510i125331D03F63A3A0%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22success.png%22%20alt%3D%22success.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELastly%20let%C2%B4s%20confirm%20in%20the%20azure%20portal%20that%20everything%20is%20created%20correctly%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22finalportal.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368511iE53BA3D699F6BCFF%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22finalportal.png%22%20alt%3D%22finalportal.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3EThen%20login%20into%20your%20workspace%20so%20you%20can%20check%20that%20the%20cluster%2C%20the%20scope%2C%20the%20secret%2C%20and%20the%20notebook%20are%20created%20and%20working%20correctly.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22workspace.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F368512i8BB33353F5FEAC96%2Fimage-size%2Flarge%3Fv%3Dv2%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22workspace.png%22%20alt%3D%22workspace.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWith%20that%20you%20can%20easily%20maintain%20your%20environments%20safe%20from%20the%20changes%20that%20contributors%20can%20do%2C%20only%20one%20way%20to%20accept%20modifications%20into%20your%20infrastructure.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%3ELet%20us%20know%20any%20comments%20or%20questions.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-3295414%22%20slang%3D%22en-US%22%3E%3CP%3EContinuous%20integration%20and%20continuous%20delivery%20(CI%2FCD)%20%26nbsp%3Bculture%20started%20to%20get%20popular%20and%20it%20brought%20the%20challenge%20of%20having%20everything%20automatized%2C%20aiming%20to%20make%20processes%20easier%20and%20maintainable%20for%20everyone.%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EOne%20of%20the%20most%20valuable%20aspects%20of%20CI%2FCD%20is%20the%20integration%20of%20the%20Infrastructure%20as%20Code%20(IaC)%20concept%2C%20with%20IaC%20we%20can%20version%20our%20infrastructure%2C%20save%20money%2C%20creating%20new%20environments%20in%20minutes%2C%20among%20many%20more%20benefits.%20I%20won't%20go%20deeper%20about%20IaC%2C%20but%20if%20you%20want%20to%20learn%20further%20visit%3A%3C%2FSPAN%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20style%3D%22font-family%3A%20inherit%3B%20background-color%3A%20%23ffffff%3B%22%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Ffasttrack-for-azure%2Fthe-benefits-of-infrastructure-as-code%2Fba-p%2F2069350%22%20target%3D%22_self%22%3EThe%20benefits%20of%20Infrastructure%20as%20Code%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EHowever%2C%20having%20IaC%20in%20our%20projects%20can%20bring%20complexity%20in%20adding%20all%20new%20technologies%20that%20are%20implemented%20in%20the%20projects%20or%20products.%20This%20is%20mostly%20due%20to%20creating%20all%20the%20scripts%20for%20the%20infrastructure%20is%20a%20task%20that%20is%20usually%20assigned%20to%20the%20infrastructure%20engineers%20and%20it%20happens%20that%20we%20can't%20have%20the%20opportunity%20to%20be%20helped%20for%20any%20reason.%3C%2FP%3E%0A%3CP%3EAs%20a%20Data%20Engineer%2C%20I%20would%20like%20to%20help%20you%20understand%20the%20CI%2FCD%20process%20with%20a%20hands-on.%20You'll%20learn%20how%20to%20create%20Azure%20Databricks%20through%20Terraform%20and%20add%20Azure%20DevOps%2C%20whether%20you%20are%20creating%20projects%20by%20yourself%20or%20supporting%20your%20Infrastructure%20Team.%3C%2FP%3E%3C%2FLINGO-TEASER%3E%3CLINGO-LABS%20id%3D%22lingo-labs-3295414%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EData%20%26amp%3B%20AI%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EInfra%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Co-Authors
Version history
Last update:
‎May 02 2022 12:38 PM
Updated by: