Azure has this built in using the Azure Image Builder. When working on windows it worked well.
https://learn.microsoft.com/en-us/azure/virtual-machines/image-builder-overview
The issue is its built ontop of HashiCorp Packer, which isn't a complete problem but ends up being a problem in certian cases. So they have done a wrapper, which means its not a strat one to one comparison to Packer. It does seem to work better arond Windows.
The biggest issue I faced was ensuring everything could be done via PowerShell. As long as your confidant with your powershell ninjutsu then it shouldn't be too bad. I created 2 images. a 2019 STIG and a 2019 STIG with custom 2019 SQL Server Installed.
If you are using GitHub Actions you can actually create a pipeline to auto create new images. That is what I did. I Would not recommend using the default Microsoft one unless you are using a private runner especially when you are in a big trial standpoint.
https://github.com/Azure/build-vm-image
The reason is it will eat up your run minutes fast as even a basic image and deployment can take 1 hour to do (it waits until its fully distributed)
I created a fork and added some extras to it so it could kill out sooner and more end around 30 minutes.