|
1 | 1 | // Azure Resource Graph query |
2 | 2 | // List public IP addresses that are not Zone-Redundant |
3 | | -Resources |
| 3 | +resources |
4 | 4 | | where type =~ "Microsoft.Network/publicIPAddresses" and sku.tier =~ "Regional" |
5 | | -| where location in~ ("australiaeast", "brazilsouth", "canadacentral", "centralindia", "centralus", "eastasia", "eastus", "eastus2", "francecentral", "germanywestcentral", "israelcentral", "italynorth", "japaneast", "japanwest", "koreacentral", "mexicocentral", "newzealandnorth", "northeurope", "norwayeast", "polandcentral", "qatarcentral", "southafricanorth", "southcentralus", "southeastasia", "spaincentral", "swedencentral", "switzerlandnorth", "uaenorth", "uksouth", "westeurope", "westus2", "westus3", "usgovvirginia", "chinanorth3") |
6 | | -| where isempty(zones) or array_length(zones) <= 1 |
| 5 | +| where |
| 6 | + (location in~ ("australiaeast", "brazilsouth", "canadacentral", "centralindia", "centralus", "eastasia", "eastus", "eastus2", "francecentral", "germanywestcentral", "israelcentral", "italynorth", "japaneast", "japanwest", "koreacentral", "mexicocentral", "newzealandnorth", "northeurope", "norwayeast", "polandcentral", "qatarcentral", "southafricanorth", "southcentralus", "southeastasia", "spaincentral", "swedencentral", "switzerlandnorth", "uaenorth", "uksouth", "westeurope", "westus2", "westus3", "usgovvirginia", "chinanorth3") |
| 7 | + and array_length(zones) <= 1) |
| 8 | + or |
| 9 | + (location in~ ("centralindia", "centralus", "eastus", "japaneast", "japanwest", "newzealandnorth","southcentralus", "southeastasia", "switzerlandnorth", "uaenorth", "westeurope", "westus3","usgovvirginia", "chinanorth3") |
| 10 | + and (isempty(zones) or array_length(zones) <= 1)) |
7 | 11 | | extend az = case(isempty(zones), "Non-zonal", array_length(zones) <= 1, strcat("Zonal (", strcat_array(zones, ","), ")"), zones) |
8 | 12 | | project recommendationId = "c63b81fb-7afc-894c-a840-91bb8a8dcfaf", name, id, tags, param1 = strcat("sku: ", sku.name), param2 = strcat("availabilityZone: ", az) |
9 | | - |
|
0 commit comments