Azure 服务健康 |所有类型的健康警报
Azure Service Health | Health alerts for all types
我想使用 ARM 模板来部署以下内容 -
服务健康 |健康警报
这将允许涵盖这些事件 -
服务、计划维护、健康咨询和安全咨询
我一直以这个模板为基础 -
https://docs.microsoft.com/en-us/azure/service-health/resource-health-alert-arm-template-guide
但这似乎并没有像我在监视器 - 警报中显示的那样提供我想要的东西
这个模板似乎做了一些,但我也需要其他类别,但运气不佳 -
https://docs.microsoft.com/en-us/azure/service-health/alerts-activity-log-service-notifications-arm?tabs=CLI
想知道是否有人遇到过这种情况,或者这是一种仅限门户的设置类型。
谢谢
请尝试以下 ARM 模板,其中包括所有事件服务、计划维护、健康咨询和安全咨询。
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"actionGroups_name": {
"defaultValue": "SubHealth",
"type": "String"
},
"activityLogAlerts_name": {
"defaultValue": "ServiceHealthActivityLogAlert",
"type": "String"
},
"emailAddress":{
"type":"string"
}
},
"variables": {
"alertScope":"[concat('/','subscriptions','/',subscription().subscriptionId)]"
},
"resources": [
{
"comments": "Action Group",
"type": "microsoft.insights/actionGroups",
"apiVersion": "2019-06-01",
"name": "[parameters('actionGroups_name')]",
"location": "Global",
"tags": {},
"scale": null,
"properties": {
"groupShortName": "[parameters('actionGroups_name')]",
"enabled": true,
"emailReceivers": [
{
"name": "[parameters('actionGroups_name')]",
"emailAddress": "[parameters('emailAddress')]"
}
],
"smsReceivers": [],
"webhookReceivers": []
},
"dependsOn": []
},
{
"comments": "Service Health Activity Log Alert",
"type": "microsoft.insights/activityLogAlerts",
"apiVersion": "2017-04-01",
"name": "[parameters('activityLogAlerts_name')]",
"location": "Global",
"tags": {},
"scale": null,
"properties": {
"scopes": [
"[variables('alertScope')]"
],
"condition": {
"allOf": [
{
"field": "category",
"equals": "ServiceHealth"
}
]
},
"actions": {
"actionGroups": [
{
"actionGroupId": "[resourceId('microsoft.insights/actionGroups', parameters('actionGroups_name'))]",
"webhookProperties": {}
}
]
},
"enabled": true,
"description": ""
},
"dependsOn": [
"[resourceId('microsoft.insights/actionGroups', parameters('actionGroups_name'))]"
]
}
] }
我想使用 ARM 模板来部署以下内容 -
服务健康 |健康警报
这将允许涵盖这些事件 - 服务、计划维护、健康咨询和安全咨询
我一直以这个模板为基础 - https://docs.microsoft.com/en-us/azure/service-health/resource-health-alert-arm-template-guide
但这似乎并没有像我在监视器 - 警报中显示的那样提供我想要的东西
这个模板似乎做了一些,但我也需要其他类别,但运气不佳 - https://docs.microsoft.com/en-us/azure/service-health/alerts-activity-log-service-notifications-arm?tabs=CLI
想知道是否有人遇到过这种情况,或者这是一种仅限门户的设置类型。
谢谢
请尝试以下 ARM 模板,其中包括所有事件服务、计划维护、健康咨询和安全咨询。
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"actionGroups_name": {
"defaultValue": "SubHealth",
"type": "String"
},
"activityLogAlerts_name": {
"defaultValue": "ServiceHealthActivityLogAlert",
"type": "String"
},
"emailAddress":{
"type":"string"
}
},
"variables": {
"alertScope":"[concat('/','subscriptions','/',subscription().subscriptionId)]"
},
"resources": [
{
"comments": "Action Group",
"type": "microsoft.insights/actionGroups",
"apiVersion": "2019-06-01",
"name": "[parameters('actionGroups_name')]",
"location": "Global",
"tags": {},
"scale": null,
"properties": {
"groupShortName": "[parameters('actionGroups_name')]",
"enabled": true,
"emailReceivers": [
{
"name": "[parameters('actionGroups_name')]",
"emailAddress": "[parameters('emailAddress')]"
}
],
"smsReceivers": [],
"webhookReceivers": []
},
"dependsOn": []
},
{
"comments": "Service Health Activity Log Alert",
"type": "microsoft.insights/activityLogAlerts",
"apiVersion": "2017-04-01",
"name": "[parameters('activityLogAlerts_name')]",
"location": "Global",
"tags": {},
"scale": null,
"properties": {
"scopes": [
"[variables('alertScope')]"
],
"condition": {
"allOf": [
{
"field": "category",
"equals": "ServiceHealth"
}
]
},
"actions": {
"actionGroups": [
{
"actionGroupId": "[resourceId('microsoft.insights/actionGroups', parameters('actionGroups_name'))]",
"webhookProperties": {}
}
]
},
"enabled": true,
"description": ""
},
"dependsOn": [
"[resourceId('microsoft.insights/actionGroups', parameters('actionGroups_name'))]"
]
}
] }