ActionRuleActionGroup

Manages an Monitor Action Rule which type is action group.

Example Usage

using Pulumi;
using Azure = Pulumi.Azure;

class MyStack : Stack
{
    public MyStack()
    {
        var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new Azure.Core.ResourceGroupArgs
        {
            Location = "West Europe",
        });
        var exampleActionGroup = new Azure.Monitoring.ActionGroup("exampleActionGroup", new Azure.Monitoring.ActionGroupArgs
        {
            ResourceGroupName = exampleResourceGroup.Name,
            ShortName = "exampleactiongroup",
        });
        var exampleActionRuleActionGroup = new Azure.Monitoring.ActionRuleActionGroup("exampleActionRuleActionGroup", new Azure.Monitoring.ActionRuleActionGroupArgs
        {
            ResourceGroupName = exampleResourceGroup.Name,
            ActionGroupId = exampleActionGroup.Id,
            Scope = new Azure.Monitoring.Inputs.ActionRuleActionGroupScopeArgs
            {
                Type = "ResourceGroup",
                ResourceIds = 
                {
                    exampleResourceGroup.Id,
                },
            },
            Tags = 
            {
                { "foo", "bar" },
            },
        });
    }

}
package main

import (
    "github.com/pulumi/pulumi-azure/sdk/v3/go/azure/core"
    "github.com/pulumi/pulumi-azure/sdk/v3/go/azure/monitoring"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
            Location: pulumi.String("West Europe"),
        })
        if err != nil {
            return err
        }
        exampleActionGroup, err := monitoring.NewActionGroup(ctx, "exampleActionGroup", &monitoring.ActionGroupArgs{
            ResourceGroupName: exampleResourceGroup.Name,
            ShortName:         pulumi.String("exampleactiongroup"),
        })
        if err != nil {
            return err
        }
        _, err = monitoring.NewActionRuleActionGroup(ctx, "exampleActionRuleActionGroup", &monitoring.ActionRuleActionGroupArgs{
            ResourceGroupName: exampleResourceGroup.Name,
            ActionGroupId:     exampleActionGroup.ID(),
            Scope: &monitoring.ActionRuleActionGroupScopeArgs{
                Type: pulumi.String("ResourceGroup"),
                ResourceIds: pulumi.StringArray{
                    exampleResourceGroup.ID(),
                },
            },
            Tags: pulumi.Map{
                "foo": pulumi.String("bar"),
            },
        })
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_azure as azure

example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
example_action_group = azure.monitoring.ActionGroup("exampleActionGroup",
    resource_group_name=example_resource_group.name,
    short_name="exampleactiongroup")
example_action_rule_action_group = azure.monitoring.ActionRuleActionGroup("exampleActionRuleActionGroup",
    resource_group_name=example_resource_group.name,
    action_group_id=example_action_group.id,
    scope={
        "type": "ResourceGroup",
        "resourceIds": [example_resource_group.id],
    },
    tags={
        "foo": "bar",
    })
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
const exampleActionGroup = new azure.monitoring.ActionGroup("exampleActionGroup", {
    resourceGroupName: exampleResourceGroup.name,
    shortName: "exampleactiongroup",
});
const exampleActionRuleActionGroup = new azure.monitoring.ActionRuleActionGroup("exampleActionRuleActionGroup", {
    resourceGroupName: exampleResourceGroup.name,
    actionGroupId: exampleActionGroup.id,
    scope: {
        type: "ResourceGroup",
        resourceIds: [exampleResourceGroup.id],
    },
    tags: {
        foo: "bar",
    },
});

Create a ActionRuleActionGroup Resource

def ActionRuleActionGroup(resource_name, opts=None, action_group_id=None, condition=None, description=None, enabled=None, name=None, resource_group_name=None, scope=None, tags=None, __props__=None);
name string
The unique name of the resource.
args ActionRuleActionGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args ActionRuleActionGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args ActionRuleActionGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

ActionRuleActionGroup Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The ActionRuleActionGroup resource accepts the following input properties:

ActionGroupId string

Specifies the resource id of monitor action group.

ResourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

Condition ActionRuleActionGroupConditionArgs

A condition block as defined below.

Description string

Specifies a description for the Action Rule.

Enabled bool

Is the Action Rule enabled? Defaults to true.

Name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

Scope ActionRuleActionGroupScopeArgs

A scope block as defined below.

Tags Dictionary<string, string>

A mapping of tags to assign to the resource.

ActionGroupId string

Specifies the resource id of monitor action group.

ResourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

Condition ActionRuleActionGroupCondition

A condition block as defined below.

Description string

Specifies a description for the Action Rule.

Enabled bool

Is the Action Rule enabled? Defaults to true.

Name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

Scope ActionRuleActionGroupScope

A scope block as defined below.

Tags map[string]string

A mapping of tags to assign to the resource.

actionGroupId string

Specifies the resource id of monitor action group.

resourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

condition ActionRuleActionGroupCondition

A condition block as defined below.

description string

Specifies a description for the Action Rule.

enabled boolean

Is the Action Rule enabled? Defaults to true.

name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

scope ActionRuleActionGroupScope

A scope block as defined below.

tags {[key: string]: string}

A mapping of tags to assign to the resource.

action_group_id str

Specifies the resource id of monitor action group.

resource_group_name str

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

condition Dict[ActionRuleActionGroupCondition]

A condition block as defined below.

description str

Specifies a description for the Action Rule.

enabled bool

Is the Action Rule enabled? Defaults to true.

name str

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

scope Dict[ActionRuleActionGroupScope]

A scope block as defined below.

tags Dict[str, str]

A mapping of tags to assign to the resource.

Outputs

All input properties are implicitly available as output properties. Additionally, the ActionRuleActionGroup resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.

Look up an Existing ActionRuleActionGroup Resource

Get an existing ActionRuleActionGroup resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

static get(resource_name, id, opts=None, action_group_id=None, condition=None, description=None, enabled=None, name=None, resource_group_name=None, scope=None, tags=None, __props__=None);
func GetActionRuleActionGroup(ctx *Context, name string, id IDInput, state *ActionRuleActionGroupState, opts ...ResourceOption) (*ActionRuleActionGroup, error)
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.

The following state arguments are supported:

ActionGroupId string

Specifies the resource id of monitor action group.

Condition ActionRuleActionGroupConditionArgs

A condition block as defined below.

Description string

Specifies a description for the Action Rule.

Enabled bool

Is the Action Rule enabled? Defaults to true.

Name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

ResourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

Scope ActionRuleActionGroupScopeArgs

A scope block as defined below.

Tags Dictionary<string, string>

A mapping of tags to assign to the resource.

ActionGroupId string

Specifies the resource id of monitor action group.

Condition ActionRuleActionGroupCondition

A condition block as defined below.

Description string

Specifies a description for the Action Rule.

Enabled bool

Is the Action Rule enabled? Defaults to true.

Name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

ResourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

Scope ActionRuleActionGroupScope

A scope block as defined below.

Tags map[string]string

A mapping of tags to assign to the resource.

actionGroupId string

Specifies the resource id of monitor action group.

condition ActionRuleActionGroupCondition

A condition block as defined below.

description string

Specifies a description for the Action Rule.

enabled boolean

Is the Action Rule enabled? Defaults to true.

name string

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

resourceGroupName string

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

scope ActionRuleActionGroupScope

A scope block as defined below.

tags {[key: string]: string}

A mapping of tags to assign to the resource.

action_group_id str

Specifies the resource id of monitor action group.

condition Dict[ActionRuleActionGroupCondition]

A condition block as defined below.

description str

Specifies a description for the Action Rule.

enabled bool

Is the Action Rule enabled? Defaults to true.

name str

Specifies the name of the Monitor Action Rule. Changing this forces a new resource to be created.

resource_group_name str

Specifies the name of the resource group in which the Monitor Action Rule should exist. Changing this forces a new resource to be created.

scope Dict[ActionRuleActionGroupScope]

A scope block as defined below.

tags Dict[str, str]

A mapping of tags to assign to the resource.

Supporting Types

ActionRuleActionGroupCondition

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

AlertContext ActionRuleActionGroupConditionAlertContextArgs

A alert_context block as defined below.

AlertRuleId ActionRuleActionGroupConditionAlertRuleIdArgs

A alert_rule_id block as defined below.

Description ActionRuleActionGroupConditionDescriptionArgs

A description block as defined below.

Monitor ActionRuleActionGroupConditionMonitorArgs

A monitor block as defined below.

MonitorService ActionRuleActionGroupConditionMonitorServiceArgs

A monitor_service as block defined below.

Severity ActionRuleActionGroupConditionSeverityArgs

A severity block as defined below.

TargetResourceType ActionRuleActionGroupConditionTargetResourceTypeArgs

A target_resource_type block as defined below.

AlertContext ActionRuleActionGroupConditionAlertContext

A alert_context block as defined below.

AlertRuleId ActionRuleActionGroupConditionAlertRuleId

A alert_rule_id block as defined below.

Description ActionRuleActionGroupConditionDescription

A description block as defined below.

Monitor ActionRuleActionGroupConditionMonitor

A monitor block as defined below.

MonitorService ActionRuleActionGroupConditionMonitorService

A monitor_service as block defined below.

Severity ActionRuleActionGroupConditionSeverity

A severity block as defined below.

TargetResourceType ActionRuleActionGroupConditionTargetResourceType

A target_resource_type block as defined below.

alertContext ActionRuleActionGroupConditionAlertContext

A alert_context block as defined below.

alertRuleId ActionRuleActionGroupConditionAlertRuleId

A alert_rule_id block as defined below.

description ActionRuleActionGroupConditionDescription

A description block as defined below.

monitor ActionRuleActionGroupConditionMonitor

A monitor block as defined below.

monitorService ActionRuleActionGroupConditionMonitorService

A monitor_service as block defined below.

severity ActionRuleActionGroupConditionSeverity

A severity block as defined below.

targetResourceType ActionRuleActionGroupConditionTargetResourceType

A target_resource_type block as defined below.

alertContext Dict[ActionRuleActionGroupConditionAlertContext]

A alert_context block as defined below.

alertRuleId Dict[ActionRuleActionGroupConditionAlertRuleId]

A alert_rule_id block as defined below.

description Dict[ActionRuleActionGroupConditionDescription]

A description block as defined below.

monitor Dict[ActionRuleActionGroupConditionMonitor]

A monitor block as defined below.

monitorService Dict[ActionRuleActionGroupConditionMonitorService]

A monitor_service as block defined below.

severity Dict[ActionRuleActionGroupConditionSeverity]

A severity block as defined below.

targetResourceType Dict[ActionRuleActionGroupConditionTargetResourceType]

A target_resource_type block as defined below.

ActionRuleActionGroupConditionAlertContext

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values List<string>

A list of values to match for a given condition.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values []string

A list of values to match for a given condition.

operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values string[]

A list of values to match for a given condition.

operator str

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values List[str]

A list of values to match for a given condition.

ActionRuleActionGroupConditionAlertRuleId

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values List<string>

A list of values to match for a given condition.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values []string

A list of values to match for a given condition.

operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values string[]

A list of values to match for a given condition.

operator str

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values List[str]

A list of values to match for a given condition.

ActionRuleActionGroupConditionDescription

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values List<string>

A list of values to match for a given condition.

Operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

Values []string

A list of values to match for a given condition.

operator string

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values string[]

A list of values to match for a given condition.

operator str

The operator for a given condition. Possible values are Equals, NotEquals, Contains, and DoesNotContain.

values List[str]

A list of values to match for a given condition.

ActionRuleActionGroupConditionMonitor

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values List<string>

A list of values to match for a given condition. Possible values are Fired and Resolved.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values []string

A list of values to match for a given condition. Possible values are Fired and Resolved.

operator string

The operator for a given condition. Possible values are Equals and NotEquals.

values string[]

A list of values to match for a given condition. Possible values are Fired and Resolved.

operator str

The operator for a given condition. Possible values are Equals and NotEquals.

values List[str]

A list of values to match for a given condition. Possible values are Fired and Resolved.

ActionRuleActionGroupConditionMonitorService

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values List<string>

A list of values to match for a given condition. Possible values are ActivityLog Administrative, ActivityLog Autoscale, ActivityLog Policy, ActivityLog Recommendation, ActivityLog Security, Application Insights, Azure Backup, Data Box Edge, Data Box Gateway, Health Platform, Log Analytics, Platform, and Resource Health.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values []string

A list of values to match for a given condition. Possible values are ActivityLog Administrative, ActivityLog Autoscale, ActivityLog Policy, ActivityLog Recommendation, ActivityLog Security, Application Insights, Azure Backup, Data Box Edge, Data Box Gateway, Health Platform, Log Analytics, Platform, and Resource Health.

operator string

The operator for a given condition. Possible values are Equals and NotEquals.

values string[]

A list of values to match for a given condition. Possible values are ActivityLog Administrative, ActivityLog Autoscale, ActivityLog Policy, ActivityLog Recommendation, ActivityLog Security, Application Insights, Azure Backup, Data Box Edge, Data Box Gateway, Health Platform, Log Analytics, Platform, and Resource Health.

operator str

The operator for a given condition. Possible values are Equals and NotEquals.

values List[str]

A list of values to match for a given condition. Possible values are ActivityLog Administrative, ActivityLog Autoscale, ActivityLog Policy, ActivityLog Recommendation, ActivityLog Security, Application Insights, Azure Backup, Data Box Edge, Data Box Gateway, Health Platform, Log Analytics, Platform, and Resource Health.

ActionRuleActionGroupConditionSeverity

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equalsand NotEquals.

Values List<string>

A list of values to match for a given condition. Possible values are Sev0, Sev1, Sev2, Sev3, and Sev4.

Operator string

The operator for a given condition. Possible values are Equalsand NotEquals.

Values []string

A list of values to match for a given condition. Possible values are Sev0, Sev1, Sev2, Sev3, and Sev4.

operator string

The operator for a given condition. Possible values are Equalsand NotEquals.

values string[]

A list of values to match for a given condition. Possible values are Sev0, Sev1, Sev2, Sev3, and Sev4.

operator str

The operator for a given condition. Possible values are Equalsand NotEquals.

values List[str]

A list of values to match for a given condition. Possible values are Sev0, Sev1, Sev2, Sev3, and Sev4.

ActionRuleActionGroupConditionTargetResourceType

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values List<string>

A list of values to match for a given condition. The values should be valid resource types.

Operator string

The operator for a given condition. Possible values are Equals and NotEquals.

Values []string

A list of values to match for a given condition. The values should be valid resource types.

operator string

The operator for a given condition. Possible values are Equals and NotEquals.

values string[]

A list of values to match for a given condition. The values should be valid resource types.

operator str

The operator for a given condition. Possible values are Equals and NotEquals.

values List[str]

A list of values to match for a given condition. The values should be valid resource types.

ActionRuleActionGroupScope

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

ResourceIds List<string>

A list of resource IDs of the given scope type which will be the target of action rule.

Type string

Specifies the type of target scope. Possible values are ResourceGroup and Resource.

ResourceIds []string

A list of resource IDs of the given scope type which will be the target of action rule.

Type string

Specifies the type of target scope. Possible values are ResourceGroup and Resource.

resourceIds string[]

A list of resource IDs of the given scope type which will be the target of action rule.

type string

Specifies the type of target scope. Possible values are ResourceGroup and Resource.

resourceIds List[str]

A list of resource IDs of the given scope type which will be the target of action rule.

type str

Specifies the type of target scope. Possible values are ResourceGroup and Resource.

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes
This Pulumi package is based on the azurerm Terraform Provider.