Skip to content

Packer and Terraform code for building a Windows Development workstation in the cloud

License

Notifications You must be signed in to change notification settings

scottford-io/windows-development-workstation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Windows Development Workstation

This project provides automation code for building a Windows 2019/2022 Developer Workstation in AWS using Packer and Terraform.

Installed Software

Both Packer templates build the AMI from the latest versions of Windows 2019 and 2022 which are maintained by Amazon on the Amazon Marketplace. During the build process, Packer installs the following dev tools:

Requirements

In order use this code with your own environment you will need the following installed on your workstation:

  • Packer
  • Terraform
  • AWS Account
  • AWS CLI Installed and Configured

Building Workstation AMI with Packer

By default the packer template builds using the default profile from the aws credentials file, and will provision in us-east-1, but both of these variables can be overridden.

cd packer
packer build aws-windows2019.pkr.hcl
amazon-ebs.windows2019: output will be in this color.

==> amazon-ebs.windows2019: Prevalidating any provided VPC information
==> amazon-ebs.windows2019: Prevalidating AMI Name: windows2019-dev-workstation-20220731223804
    amazon-ebs.windows2019: Found Image ID: ami-05912b6333beaa478
==> amazon-ebs.windows2019: Creating temporary keypair: packer_62e7044c-e50e-c9ad-01ea-b2c80060c68e
==> amazon-ebs.windows2019: Creating temporary security group for this instance: packer_62e70452-0b4b-14a5-7b6f-c0f683e8627f
==> amazon-ebs.windows2019: Authorizing access to port 5985 from [0.0.0.0/0] in the temporary security groups...
==> amazon-ebs.windows2019: Launching a source AWS instance...==> Wait completed after 20 minutes 16 seconds

==> Builds finished. The artifacts of successful builds are:
--> amazon-ebs: AMIs were created:
us-east-1: ami-0d4e8c2c7b3abc123

At the end of the Packer run you will see the generated ami-. Copy that ami id and move on to Terraform.

Provisioning an instance with Terraform

The Terraform code will create a VPC, Security group, and an instance of the Windows 2019 Dev Workstation. Checkout the variables.tf to override configuration using a terraform.tfvars file.

cd terraform
terraform init
terraform plan
terraform apply -auto-approve

Once complete, Terraform will print out the public_ip of the Windows instance and you can RDP to it.

Windows Admin Password

The AMI is provisioned with the default password C10udp1@gr0und2023. This can be override, but the password must meet Windows 2022 default password complexity requirements:

  • Uppercase letters of European languages (A through Z, with diacritic marks, Greek and Cyrillic characters).

  • Lowercase letters of European languages (a through z, sharp-s, with diacritic marks, Greek and Cyrillic characters).

  • Base 10 digits (0 through 9).

  • Non-alphanumeric characters (special characters):

    '-!"#$%&()*,./:;?@[]^_`{|}~+<=>
    

About

Packer and Terraform code for building a Windows Development workstation in the cloud

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published