az new-relic monitor tag-rule

Note

This reference is part of the new-relic extension for the Azure CLI (version 2.61.0 or higher). The extension will automatically install the first time you run an az new-relic monitor tag-rule command. Learn more about extensions.

Provides a set of commands to manage tag rules for New Relic monitor resources, allowing you to control which Azure resources are monitored based on their tags.

Commands

Name Description Type Status
az new-relic monitor tag-rule create

Creates a new set of tag rules for a specific New Relic monitor resource, determining which Azure resources are monitored based on their tags.

Extension GA
az new-relic monitor tag-rule delete

Delete a tag rule set for a given New Relic monitor resource, removing fine-grained control over observability based on resource tags.

Extension GA
az new-relic monitor tag-rule list

Lists all tag rules associated with a specific New Relic monitor resource, helping you manage and audit the rules that control resource monitoring.

Extension GA
az new-relic monitor tag-rule show

Retrieves the details of the tag rules for a specific New Relic monitor resource, providing insight into its setup and status.

Extension GA
az new-relic monitor tag-rule update

Update the tag rules for a specific New Relic monitor resource, allowing you to modify the rules that control which Azure resources are monitored.

Extension GA
az new-relic monitor tag-rule wait

Place the CLI in a waiting state until a condition is met.

Extension GA

az new-relic monitor tag-rule create

Creates a new set of tag rules for a specific New Relic monitor resource, determining which Azure resources are monitored based on their tags.

az new-relic monitor tag-rule create --monitor-name
                                     --resource-group
                                     [--acquire-policy-token]
                                     [--change-reference]
                                     [--log-rules]
                                     [--metric-rules]
                                     [--name --rule-set-name]
                                     [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]

Examples

Create a tag rule for a New Relic monitor

az new-relic monitor tag-rule create --resource-group myResourceGroup --monitor-name myNewRelicMonitor --name default --log-rules send-aad-logs=Enabled send-subscription-logs=Enabled send-activity-logs=Enabled filtering-tags=[] --metric-rules send-metrics=Enabled user-email=user@example.com filtering-tags="[{name:Environment,value:Production,action:Include}]"

Required Parameters

--monitor-name

Name of the Monitoring resource.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--acquire-policy-token

Acquiring an Azure Policy token automatically for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--change-reference

The related change reference ID for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--log-rules

Set of rules for sending logs for the Monitor resource. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.

Property Value
Parameter group: Properties Arguments
--metric-rules

Set of rules for sending metrics for the Monitor resource. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.

Property Value
Parameter group: Properties Arguments
--name --rule-set-name -n

Name of the TagRule.

Property Value
Default value: default
--no-wait

Do not wait for the long-running operation to finish.

Property Value
Accepted values: 0, 1, f, false, n, no, t, true, y, yes
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az new-relic monitor tag-rule delete

Delete a tag rule set for a given New Relic monitor resource, removing fine-grained control over observability based on resource tags.

az new-relic monitor tag-rule delete [--acquire-policy-token]
                                     [--change-reference]
                                     [--ids]
                                     [--monitor-name]
                                     [--name --rule-set-name]
                                     [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                                     [--resource-group]
                                     [--subscription]

Examples

Delete a TagRule.

az new-relic monitor tag-rule delete --resource-group MyResourceGroup --monitor-name MyNewRelicMonitor --name default

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--acquire-policy-token

Acquiring an Azure Policy token automatically for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--change-reference

The related change reference ID for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--monitor-name

Name of the Monitoring resource.

Property Value
Parameter group: Resource Id Arguments
--name --rule-set-name -n

Name of the TagRule.

Property Value
Parameter group: Resource Id Arguments
Default value: default
--no-wait

Do not wait for the long-running operation to finish.

Property Value
Accepted values: 0, 1, f, false, n, no, t, true, y, yes
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az new-relic monitor tag-rule list

Lists all tag rules associated with a specific New Relic monitor resource, helping you manage and audit the rules that control resource monitoring.

az new-relic monitor tag-rule list --monitor-name
                                   --resource-group
                                   [--max-items]
                                   [--next-token]

Examples

List TagRule resources by NewRelicMonitorResource.

az new-relic monitor tag-rule list --resource-group MyResourceGroup --monitor-name MyNewRelicMonitor

Required Parameters

--monitor-name

Name of the Monitoring resource.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--max-items

Total number of items to return in the command's output. If the total number of items available is more than the value specified, a token is provided in the command's output. To resume pagination, provide the token value in --next-token argument of a subsequent command.

Property Value
Parameter group: Pagination Arguments
--next-token

Token to specify where to start paginating. This is the token value from a previously truncated response.

Property Value
Parameter group: Pagination Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az new-relic monitor tag-rule show

Retrieves the details of the tag rules for a specific New Relic monitor resource, providing insight into its setup and status.

az new-relic monitor tag-rule show [--ids]
                                   [--monitor-name]
                                   [--name --rule-set-name]
                                   [--resource-group]
                                   [--subscription]

Examples

Get a TagRule.

az new-relic monitor tag-rule show --resource-group MyResourceGroup --monitor-name MyNewRelicMonitor --name default

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--monitor-name

Name of the Monitoring resource.

Property Value
Parameter group: Resource Id Arguments
--name --rule-set-name -n

Name of the TagRule.

Property Value
Parameter group: Resource Id Arguments
Default value: default
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az new-relic monitor tag-rule update

Update the tag rules for a specific New Relic monitor resource, allowing you to modify the rules that control which Azure resources are monitored.

az new-relic monitor tag-rule update [--acquire-policy-token]
                                     [--change-reference]
                                     [--ids]
                                     [--log-rules]
                                     [--metric-rules]
                                     [--monitor-name]
                                     [--name --rule-set-name]
                                     [--resource-group]
                                     [--subscription]

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--acquire-policy-token

Acquiring an Azure Policy token automatically for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--change-reference

The related change reference ID for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--log-rules

Set of rules for sending logs for the Monitor resource. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.

Property Value
Parameter group: Properties Arguments
--metric-rules

Set of rules for sending metrics for the Monitor resource. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.

Property Value
Parameter group: Properties Arguments
--monitor-name

Name of the Monitors resource.

Property Value
Parameter group: Resource Id Arguments
--name --rule-set-name -n

Name of the TagRule.

Property Value
Parameter group: Resource Id Arguments
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az new-relic monitor tag-rule wait

Place the CLI in a waiting state until a condition is met.

az new-relic monitor tag-rule wait [--acquire-policy-token]
                                   [--change-reference]
                                   [--created]
                                   [--custom]
                                   [--deleted]
                                   [--exists]
                                   [--ids]
                                   [--interval]
                                   [--monitor-name]
                                   [--name --rule-set-name]
                                   [--resource-group]
                                   [--subscription]
                                   [--timeout]
                                   [--updated]

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--acquire-policy-token

Acquiring an Azure Policy token automatically for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--change-reference

The related change reference ID for this resource operation.

Property Value
Parameter group: Global Policy Arguments
--created

Wait until created with 'provisioningState' at 'Succeeded'.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--custom

Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].

Property Value
Parameter group: Wait Condition Arguments
--deleted

Wait until deleted.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--exists

Wait until the resource exists.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--interval

Polling interval in seconds.

Property Value
Parameter group: Wait Condition Arguments
Default value: 30
--monitor-name

Name of the Monitoring resource.

Property Value
Parameter group: Resource Id Arguments
--name --rule-set-name -n

Name of the TagRule.

Property Value
Parameter group: Resource Id Arguments
Default value: default
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
--timeout

Maximum wait in seconds.

Property Value
Parameter group: Wait Condition Arguments
Default value: 3600
--updated

Wait until updated with provisioningState at 'Succeeded'.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False