Oracle Cloud Infrastructure

Pulumi Official
Package maintained by Pulumi
v0.1.1 published on Tuesday, May 3, 2022 by Pulumi

getAlertPolicyRule

This data source provides details about a specific Alert Policy Rule resource in Oracle Cloud Infrastructure Data Safe service.

Lists the rules of the specified alert policy. The alert policy is said to be satisfied when all rules in the policy evaulate to true. If there are three rules: rule1,rule2 and rule3, the policy is satisfied if rule1 AND rule2 AND rule3 is True.

Example Usage

using Pulumi;
using Oci = Pulumi.Oci;

class MyStack : Stack
{
    public MyStack()
    {
        var testAlertPolicyRule = Output.Create(Oci.DataSafe.GetAlertPolicyRule.InvokeAsync(new Oci.DataSafe.GetAlertPolicyRuleArgs
        {
            AlertPolicyId = oci_data_safe_alert_policy.Test_alert_policy.Id,
        }));
    }

}
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/go/oci/DataSafe"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := DataSafe.GetAlertPolicyRule(ctx, &datasafe.GetAlertPolicyRuleArgs{
			AlertPolicyId: oci_data_safe_alert_policy.Test_alert_policy.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_oci as oci

test_alert_policy_rule = oci.DataSafe.get_alert_policy_rule(alert_policy_id=oci_data_safe_alert_policy["test_alert_policy"]["id"])
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testAlertPolicyRule = oci.DataSafe.getAlertPolicyRule({
    alertPolicyId: oci_data_safe_alert_policy.test_alert_policy.id,
});

Coming soon!

Using getAlertPolicyRule

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getAlertPolicyRule(args: GetAlertPolicyRuleArgs, opts?: InvokeOptions): Promise<GetAlertPolicyRuleResult>
function getAlertPolicyRuleOutput(args: GetAlertPolicyRuleOutputArgs, opts?: InvokeOptions): Output<GetAlertPolicyRuleResult>
def get_alert_policy_rule(alert_policy_id: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetAlertPolicyRuleResult
def get_alert_policy_rule_output(alert_policy_id: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetAlertPolicyRuleResult]
func GetAlertPolicyRule(ctx *Context, args *GetAlertPolicyRuleArgs, opts ...InvokeOption) (*GetAlertPolicyRuleResult, error)
func GetAlertPolicyRuleOutput(ctx *Context, args *GetAlertPolicyRuleOutputArgs, opts ...InvokeOption) GetAlertPolicyRuleResultOutput

> Note: This function is named GetAlertPolicyRule in the Go SDK.

public static class GetAlertPolicyRule 
{
    public static Task<GetAlertPolicyRuleResult> InvokeAsync(GetAlertPolicyRuleArgs args, InvokeOptions? opts = null)
    public static Output<GetAlertPolicyRuleResult> Invoke(GetAlertPolicyRuleInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAlertPolicyRuleResult> getAlertPolicyRule(GetAlertPolicyRuleArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: oci:DataSafe/getAlertPolicyRule:getAlertPolicyRule
  Arguments:
    # Arguments dictionary

The following arguments are supported:

AlertPolicyId string

The OCID of the alert policy.

AlertPolicyId string

The OCID of the alert policy.

alertPolicyId String

The OCID of the alert policy.

alertPolicyId string

The OCID of the alert policy.

alert_policy_id str

The OCID of the alert policy.

alertPolicyId String

The OCID of the alert policy.

getAlertPolicyRule Result

The following output properties are available:

AlertPolicyId string
Id string

The provider-assigned unique ID for this managed resource.

Items List<GetAlertPolicyRuleItem>

Array of alert policy rules summary

AlertPolicyId string
Id string

The provider-assigned unique ID for this managed resource.

Items []GetAlertPolicyRuleItem

Array of alert policy rules summary

alertPolicyId String
id String

The provider-assigned unique ID for this managed resource.

items List<GetAlertPolicyRuleItem>

Array of alert policy rules summary

alertPolicyId string
id string

The provider-assigned unique ID for this managed resource.

items GetAlertPolicyRuleItem[]

Array of alert policy rules summary

alert_policy_id str
id str

The provider-assigned unique ID for this managed resource.

items GetAlertPolicyRuleItem]

Array of alert policy rules summary

alertPolicyId String
id String

The provider-assigned unique ID for this managed resource.

items List<Property Map>

Array of alert policy rules summary

Supporting Types

GetAlertPolicyRuleItem

Description string

Describes the alert policy rule.

Expression string

The conditional expression of the alert policy rule which evaluates to boolean value.

Key string

The unique key of the alert policy rule.

Description string

Describes the alert policy rule.

Expression string

The conditional expression of the alert policy rule which evaluates to boolean value.

Key string

The unique key of the alert policy rule.

description String

Describes the alert policy rule.

expression String

The conditional expression of the alert policy rule which evaluates to boolean value.

key String

The unique key of the alert policy rule.

description string

Describes the alert policy rule.

expression string

The conditional expression of the alert policy rule which evaluates to boolean value.

key string

The unique key of the alert policy rule.

description str

Describes the alert policy rule.

expression str

The conditional expression of the alert policy rule which evaluates to boolean value.

key str

The unique key of the alert policy rule.

description String

Describes the alert policy rule.

expression String

The conditional expression of the alert policy rule which evaluates to boolean value.

key String

The unique key of the alert policy rule.

Package Details

Repository
https://github.com/pulumi/pulumi-oci
License
Apache-2.0
Notes

This Pulumi package is based on the oci Terraform Provider.