1. Packages
  2. OVH
  3. API Docs
  4. CloudProject
  5. Alerting
OVHCloud v0.42.0 published on Tuesday, Apr 9, 2024 by OVHcloud

ovh.CloudProject.Alerting

Explore with Pulumi AI

ovh logo
OVHCloud v0.42.0 published on Tuesday, Apr 9, 2024 by OVHcloud

    Creates an alert on a public cloud project.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@ovhcloud/pulumi-ovh";
    
    const my_alert = new ovh.cloudproject.Alerting("my-alert", {
        delay: 3600,
        email: "aaa.bbb@domain.com",
        monthlyThreshold: 1000,
        serviceName: "XXX",
    });
    
    import pulumi
    import pulumi_ovh as ovh
    
    my_alert = ovh.cloud_project.Alerting("my-alert",
        delay=3600,
        email="aaa.bbb@domain.com",
        monthly_threshold=1000,
        service_name="XXX")
    
    package main
    
    import (
    	"github.com/ovh/pulumi-ovh/sdk/go/ovh/CloudProject"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := CloudProject.NewAlerting(ctx, "my-alert", &CloudProject.AlertingArgs{
    			Delay:            pulumi.Float64(3600),
    			Email:            pulumi.String("aaa.bbb@domain.com"),
    			MonthlyThreshold: pulumi.Float64(1000),
    			ServiceName:      pulumi.String("XXX"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var my_alert = new Ovh.CloudProject.Alerting("my-alert", new()
        {
            Delay = 3600,
            Email = "aaa.bbb@domain.com",
            MonthlyThreshold = 1000,
            ServiceName = "XXX",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ovh.CloudProject.Alerting;
    import com.pulumi.ovh.CloudProject.AlertingArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var my_alert = new Alerting("my-alert", AlertingArgs.builder()        
                .delay(3600)
                .email("aaa.bbb@domain.com")
                .monthlyThreshold(1000)
                .serviceName("XXX")
                .build());
    
        }
    }
    
    resources:
      my-alert:
        type: ovh:CloudProject:Alerting
        properties:
          delay: 3600
          email: aaa.bbb@domain.com
          monthlyThreshold: 1000
          serviceName: XXX
    

    Create Alerting Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Alerting(name: string, args: AlertingArgs, opts?: CustomResourceOptions);
    @overload
    def Alerting(resource_name: str,
                 args: AlertingArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Alerting(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 delay: Optional[float] = None,
                 email: Optional[str] = None,
                 monthly_threshold: Optional[float] = None,
                 service_name: Optional[str] = None)
    func NewAlerting(ctx *Context, name string, args AlertingArgs, opts ...ResourceOption) (*Alerting, error)
    public Alerting(string name, AlertingArgs args, CustomResourceOptions? opts = null)
    public Alerting(String name, AlertingArgs args)
    public Alerting(String name, AlertingArgs args, CustomResourceOptions options)
    
    type: ovh:CloudProject:Alerting
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args AlertingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args AlertingArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args AlertingArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AlertingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AlertingArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var alertingResource = new Ovh.CloudProject.Alerting("alertingResource", new()
    {
        Delay = 0,
        Email = "string",
        MonthlyThreshold = 0,
        ServiceName = "string",
    });
    
    example, err := CloudProject.NewAlerting(ctx, "alertingResource", &CloudProject.AlertingArgs{
    	Delay:            pulumi.Float64(0),
    	Email:            pulumi.String("string"),
    	MonthlyThreshold: pulumi.Float64(0),
    	ServiceName:      pulumi.String("string"),
    })
    
    var alertingResource = new Alerting("alertingResource", AlertingArgs.builder()        
        .delay(0)
        .email("string")
        .monthlyThreshold(0)
        .serviceName("string")
        .build());
    
    alerting_resource = ovh.cloud_project.Alerting("alertingResource",
        delay=0,
        email="string",
        monthly_threshold=0,
        service_name="string")
    
    const alertingResource = new ovh.cloudproject.Alerting("alertingResource", {
        delay: 0,
        email: "string",
        monthlyThreshold: 0,
        serviceName: "string",
    });
    
    type: ovh:CloudProject:Alerting
    properties:
        delay: 0
        email: string
        monthlyThreshold: 0
        serviceName: string
    

    Alerting Resource Properties

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

    Inputs

    The Alerting resource accepts the following input properties:

    Delay double
    Delay between two alerts in seconds
    Email string
    Email to contact
    MonthlyThreshold double
    Monthly threshold for this alerting in currency
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    Delay float64
    Delay between two alerts in seconds
    Email string
    Email to contact
    MonthlyThreshold float64
    Monthly threshold for this alerting in currency
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    delay Double
    Delay between two alerts in seconds
    email String
    Email to contact
    monthlyThreshold Double
    Monthly threshold for this alerting in currency
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    delay number
    Delay between two alerts in seconds
    email string
    Email to contact
    monthlyThreshold number
    Monthly threshold for this alerting in currency
    serviceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    delay float
    Delay between two alerts in seconds
    email str
    Email to contact
    monthly_threshold float
    Monthly threshold for this alerting in currency
    service_name str
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    delay Number
    Delay between two alerts in seconds
    email String
    Email to contact
    monthlyThreshold Number
    Monthly threshold for this alerting in currency
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

    Outputs

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

    CreationDate string
    Alerting creation date
    FormattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    Id string
    The provider-assigned unique ID for this managed resource.
    CreationDate string
    Alerting creation date
    FormattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    Id string
    The provider-assigned unique ID for this managed resource.
    creationDate String
    Alerting creation date
    formattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    id String
    The provider-assigned unique ID for this managed resource.
    creationDate string
    Alerting creation date
    formattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    id string
    The provider-assigned unique ID for this managed resource.
    creation_date str
    Alerting creation date
    formatted_monthly_threshold cloudproject.AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    id str
    The provider-assigned unique ID for this managed resource.
    creationDate String
    Alerting creation date
    formattedMonthlyThreshold Property Map
    Formatted monthly threshold for this alerting
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Alerting Resource

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

    public static get(name: string, id: Input<ID>, state?: AlertingState, opts?: CustomResourceOptions): Alerting
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            creation_date: Optional[str] = None,
            delay: Optional[float] = None,
            email: Optional[str] = None,
            formatted_monthly_threshold: Optional[_cloudproject.AlertingFormattedMonthlyThresholdArgs] = None,
            monthly_threshold: Optional[float] = None,
            service_name: Optional[str] = None) -> Alerting
    func GetAlerting(ctx *Context, name string, id IDInput, state *AlertingState, opts ...ResourceOption) (*Alerting, error)
    public static Alerting Get(string name, Input<string> id, AlertingState? state, CustomResourceOptions? opts = null)
    public static Alerting get(String name, Output<String> id, AlertingState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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.
    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:
    CreationDate string
    Alerting creation date
    Delay double
    Delay between two alerts in seconds
    Email string
    Email to contact
    FormattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    MonthlyThreshold double
    Monthly threshold for this alerting in currency
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    CreationDate string
    Alerting creation date
    Delay float64
    Delay between two alerts in seconds
    Email string
    Email to contact
    FormattedMonthlyThreshold AlertingFormattedMonthlyThresholdArgs
    Formatted monthly threshold for this alerting
    MonthlyThreshold float64
    Monthly threshold for this alerting in currency
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    creationDate String
    Alerting creation date
    delay Double
    Delay between two alerts in seconds
    email String
    Email to contact
    formattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    monthlyThreshold Double
    Monthly threshold for this alerting in currency
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    creationDate string
    Alerting creation date
    delay number
    Delay between two alerts in seconds
    email string
    Email to contact
    formattedMonthlyThreshold AlertingFormattedMonthlyThreshold
    Formatted monthly threshold for this alerting
    monthlyThreshold number
    Monthly threshold for this alerting in currency
    serviceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    creation_date str
    Alerting creation date
    delay float
    Delay between two alerts in seconds
    email str
    Email to contact
    formatted_monthly_threshold cloudproject.AlertingFormattedMonthlyThresholdArgs
    Formatted monthly threshold for this alerting
    monthly_threshold float
    Monthly threshold for this alerting in currency
    service_name str
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    creationDate String
    Alerting creation date
    delay Number
    Delay between two alerts in seconds
    email String
    Email to contact
    formattedMonthlyThreshold Property Map
    Formatted monthly threshold for this alerting
    monthlyThreshold Number
    Monthly threshold for this alerting in currency
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

    Supporting Types

    AlertingFormattedMonthlyThreshold, AlertingFormattedMonthlyThresholdArgs

    CurrencyCode string
    Currency of the monthly threshold
    Text string
    Text representation of the monthly threshold
    Value double
    Value of the monthly threshold
    CurrencyCode string
    Currency of the monthly threshold
    Text string
    Text representation of the monthly threshold
    Value float64
    Value of the monthly threshold
    currencyCode String
    Currency of the monthly threshold
    text String
    Text representation of the monthly threshold
    value Double
    Value of the monthly threshold
    currencyCode string
    Currency of the monthly threshold
    text string
    Text representation of the monthly threshold
    value number
    Value of the monthly threshold
    currency_code str
    Currency of the monthly threshold
    text str
    Text representation of the monthly threshold
    value float
    Value of the monthly threshold
    currencyCode String
    Currency of the monthly threshold
    text String
    Text representation of the monthly threshold
    value Number
    Value of the monthly threshold

    Package Details

    Repository
    ovh ovh/pulumi-ovh
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ovh Terraform Provider.
    ovh logo
    OVHCloud v0.42.0 published on Tuesday, Apr 9, 2024 by OVHcloud