Terraform on Azure - Basic Tutorial
- Visual Studio Code
- Terraform Setup
- Microsoft Azure Subscriptions
- Azure CLI Setup
Terraform is an open-source infrastructure as a code software tool created by HashiCorp. Users define and provide data center infrastructure using a declarative configuration language known as HashiCorp Configuration Language, or optionally JSON
We will start with the very basics and methodically build from there, learning new information, tricks, and skills along the way! Most lessons are less than 8 minutes long to help ensure a pace that doesn't put you to sleep
What will you learn?
· Introduction of Terraform.
· Installation of Terraform and setting up Environment path.
· Visual Studio Code installation and setting up extension for Terraform.
· Installation of Azure Command Line Interface (CLI).
· Azure Authentication using Azure CLI to perform Terraform Deployment.
· Azure Provider details and how to search template in Terraform Azure Documentation.
· Terraform init execution -
The terraform init command is used to initialize a working directory containing Terraform configuration files. This is the first command that should be run after writing a new Terraform configuration or cloning an existing one from version control. It is safe to run this command multiple times.
· Terraform Plan execution -
1. Reading the current state of any already-existing remote objects to make sure that the Terraform state is up-to-date.
2. Comparing the current configuration to the prior state and noting any differences.
3. Proposing a set of change actions that should, if applied, make the remote objects match the configuration.
4. The plan command alone will not actually carry out the proposed changes, and so you can use this command to check whether the proposed changes match what you expected before you apply the changes or share your changes with your team for broader review.
· Terraform Apply execution –
1. The terraform apply command executes the actions proposed in a Terraform plan.
2. The most straightforward way to use terraform apply is to run it without any arguments at all, in which case it will automatically create a new execution plan (as if you had run terraform plan) and then prompt you to approve that plan, before taking the indicated actions.
· Terraform State File explanation.
· Terraform Destroy command execution and explanation.
· How to use Interpolation n Resource Block.
· Create variables and use that as interpolation in Resource Block.
· Create Local block and use that as reference in Resource Block.
· How to setup Terraform remote backend to save state file in Azure Storage Account.
· Create output block to store Resource details in state file.
· How to create data block to captured state file details
· Virtual Machine Creation
Who this course is for:
- Beginner DevOps engineers curious about Infrastructure as Code.
Motivated Self-Starter with 7+ years of experience working as an Automation lead. I have worked in various domains like Exchange, Lync, Active Directory, O365, Azure, AWS, DevOps. I have Practical knowledge of different scripting languages like PowerShell, Python, YAML, JSON, Batch. My online courses focus on providing Hands-on Experience that makes learning really interesting.
I am an Automation enthusiast for many reasons, and I'd like to share that passion with you too!