Azure: Deploy a simple Windows VM (101-vm-simple-windows) using Terraform

This terraform configuration will deploy a simple Windows VM on Azure cloud, and this is a conversion of 101-vm-simple-windows from azure_quickstart_templates. This configuration consists of two .tf files ( and and deploy a single vm with the following resources…

  • Visualized in ARMVIZ


  • Deployed resources




Variables are separated from the main configuration, and this configuration accepts the variable below…


This file contains the actual configuration to create a simple Windows VM…

Deploy the configuration


Please use AzureCli to authenticate to your Azure cloud environment, terraform can use the same session to deploy the resources. Check here for alternate methods of authentication.


First time you need to initialize the configuration directory, where it will download the necessary plugins to deploy the current configuration, to initialize you need to run the command below…

terraform init


Terraform will check for the syntax errors and generates the execution plan, you can also save this plan for your future deployments

terraform plan


To apply the configuration run the command below…

terraform apply

Thank you.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.