New-CmAzMonitorServiceHealthAlerts

Allows definition and deployment of service health alerts.

Deploys service health alerts, which in turn are linked to specified action groups.

This command forms part of the Monitor Building Block.

Parameters

-SettingsFile

Required. (String) File path for the settings file to be converted into a settings object.

-SettingsObject

Required. (Object) Object containing the configuration values required to run this cmdlet.

-TagSettingsFile

Required. (String) File path for the tag settings file to be converted into a tag settings object.

-WhatIf

(Switch) Run the command without executing any actions, so that no changes are made. The command will output a description of actions to be performed against the affected resources in the console window. Use this option if you are unsure of the overall impact of your command and wish to review it before committing to making changes.

-Confirm

(Switch) Run the command without executing any actions, so that no changes are made. The command will output a description of actions to be performed against the affected resources in the console window. Use this option if you are unsure of the overall impact of your command and wish to review it before committing to making changes.

Usage

Example 1

1
New-CmAzMonitorServiceHealthAlerts -SettingsFile "c:\directory\settingsFile.yml" -Confirm:$false

Example 2

1
New-CmAzMonitorServiceHealthAlerts -SettingsObject $settings

Settings

Beta documentation
The following schema documentation is automatically generated as part of a recent roadmap task. There may be inaccuracies or incomplete information while we flush out bugs; please refer to the packed project settings examples where necessary.

Settings Root.

Component

component [string | null] Mandatory

Value to determine what cmdlet should be dynamically loaded for these settings.

location

location [string | null]

Deployment location which is also used for created dedicated resource group if required.

Service

service [object]

Contains dependency and publish details for service location.

Dependencies

dependencies [object]

Contains dependency details for service location.

Action Groups

actionGroups [array | null]

Global default dependency value to fetch existing resource type.

ResourceGroup

resourceGroup [string | null]

Dependency value to fetch existing resource type.

Publish

publish [object | null]

Contains publish details for service location.

Service Health Alert

serviceHealthAlert [string | null]

Global default value to publish on deployed resource type.

ResourceGroup

resourceGroup [string | null]

Global default value to publish on deployed resource type.

Groups

alerts [array] Mandatory

Contains all details pertaining to logical groupings of alert sets.

Name

name []

Becomes part of activity log alert rule generated name.

Description

description [string | null]

Description of the activity log alert rule.

Enabled

enabled [boolean | null]

If the alert rule is enabled or not.

Default:true

Services

services [array | null]

Filter with services.

EventTypes

eventTypes [array | null]

Filter with event types.

Regions

regions [array]

Filter with regions.

Service

service [object | null]

Contains dependency and publish details for service location.

Dependencies

dependencies [object | null]

Contains dependency details for service location.

Action Groups

actionGroups [array | null]

Local overriding dependency value to fetch existing resource type.

Publish

publish [object | null]

Contains publish details for service location.

Service Health Alert

serviceHealthAlert [string | null]

Local overriding value to publish on deployed existing resource type.

Examples

The following example files are automatically generated from the settings file schema definition to show how the specification can be used in practise. Cloudmarque can accept both JSON and YAML parameter files.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{
  "component": "string",
  "location": "string",
  "service": {
    "dependencies": {
      "actionGroups": [

      ],
      "resourceGroup": "string"
    },
    "publish": {
      "serviceHealthAlert": "string",
      "resourceGroup": "string"
    }
  },
  "alerts": [
    {
      "name": "unknown",
      "description": "string",
      "enabled": "true",
      "services": [

      ],
      "eventTypes": [

      ],
      "regions": [

      ],
      "service": {
        "dependencies": {
          "actionGroups": [

          ]
        },
        "publish": {
          "serviceHealthAlert": "string"
        }
      }
    }
  ]
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
component: "string"    # Mandatory
location: "string"    # Optional
service:     # Optional
  dependencies:     # Optional
    actionGroups:     # Optional
      -     resourceGroup: "string"    # Optional
  publish:     # Optional
    serviceHealthAlert: "string"    # Optional
    resourceGroup: "string"    # Optional
alerts:     # Mandatory
  - name: "unknown"    # Optional
    description: "string"    # Optional
    enabled: "true"    # Optional
    services:     # Optional
      -     eventTypes:     # Optional
      -     regions:     # Optional
      -     service:     # Optional
      dependencies:     # Optional
        actionGroups:     # Optional
          -       publish:     # Optional
        serviceHealthAlert: "string"    # Optional