How to create an alert rule using PowerShell and Azure CLI
I found it rather difficult to create an alert rule using PowerShell as opossed to using Azure CLI. That's why I thought its worth a post. I assume there exists a resource-group called rg-training and a VM named VM1. In general an alert rule consists of the following components…