azsk / AzTS-docs

MIT License
280 stars 84 forks source link

Move to latest syntax for action groups #466

Open akanieski opened 1 month ago

akanieski commented 1 month ago

Running the AZTS Install-AzSKTenantSecuritySolution command displays an error message during operation. It appears to stumble over the creation of the Action Groups for Azure Monitor alerts.

VERBOSE: 16:30:41 - Creating monitoring alerts...
The term 'New-AzActionGroupReceiver' is not recognized as the name of a cmdlet, function, script file, or operable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.                   

After researching I found that current Azure Powershell cmdlet's syntax has changed. That being said I took the time to move to the latest syntax to address this error.

Prior Version https://learn.microsoft.com/en-us/powershell/module/az.monitor/new-azactiongroup?view=azps-0.10.0 New Version https://learn.microsoft.com/en-us/powershell/module/az.monitor/new-azactiongroupemailreceiverobject?view=azps-12.1.0