Skip to content
This repository has been archived by the owner on Jan 5, 2022. It is now read-only.

This repository shows how to create a VM Scale Set from an Golden image published to the Azure Shared Image Gallery.

License

Notifications You must be signed in to change notification settings

briandenicola/azure-vmss-from-shared-image

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This repository shows how to create a VM Scale Set from an Golden image published to the Azure Shared Image Gallery. It uses Azure DevOps Pipelines for CI/CD. The Pipelines are defined in the Pipelines directory.

  • SharedImageAndScaleSet.build.yaml - This just copies the json scripts in preperation release. Should use a linter to check json syntax
  • SharedImageGalley.release.yaml - Created a Golden image using Packer and distribute the image via Shared Image Gallerys to multiple Azure regions
  • ScaleSet.release.yaml - Creates a 5 node Azure Scale Set from the Golden Image.

PreReq

    publisher="bjdazure.demo"
    gallery="BjdAzureDemoGallery"
    offer="BaseIISStandard"
    sku="BaseIIS"
    replica=1
    location="southcentralus"
    RG="Shared_Images_RG"

    az group create -n $RG -l $location
    az sig create -g $RG --gallery-name $gallery
    az sig image-definition create -g $RG --gallery-name $gallery --gallery-image-definition $offer --publisher $publisher --offer $offer --sku $sku --os-type Windows 

Golden Image

  • The Golden Image is created from the base Azure Windows 2016 Datacenter Image
  • IIS is installed and a default page created.
  • This process is handled by Packer using Azure DevOps autogenerated Packer Template. A custom template can also be supplied.

VM Scale Set

  • The VMSS image is created from the Golden Image created above
  • A powershell script determines the latest build via the buildid tag on image
  • A new VM image will be created with additional code deployed to IIS
  • An Azure Load Balancer is created and the Scale Sett attached to it.

About

This repository shows how to create a VM Scale Set from an Golden image published to the Azure Shared Image Gallery.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published