Photo by Hal Gatewood on Unsplash

How to use Packer to build a Windows Server Image for Azure

Guillermo Musumeci

--

Packer is an open-source tool used to create virtual machine templates from a .json file.

In this story, we will learn how to use Packer to define and build custom images in Azure, and then use this image to build a Windows virtual machine using Terraform.

1. Prerequisites

To create our own custom virtual machine images in Azure with Packer, we will need Packer (pretty obvious) and a couple of resources in Azure.

1.1. Packer

Packer is available to download at https://www.packer.io as a single binary file.

We can download Packer binary for macOS, Linux, or Windows from the Packer web site

We can install on macOS using Homebrew by executing brew install packer

We can install on Linux using apt-get by executing apt-get install packer

1.2. How to Install Packer in Windows?

The process is very simple.

1.3. Azure Prerequisites

--

--

Guillermo Musumeci
Guillermo Musumeci

Written by Guillermo Musumeci

Certified AWS, Azure & GCP Architect | HashiCorp Ambassador | Terraform SME | KopiCloud Founder | ex-AWS | Entrepreneur | Book Author | Husband & Dad of ✌

Responses (2)