SiteMonitorArgs

data class SiteMonitorArgs(val address: Output<String>? = null, val alertIds: Output<List<String>>? = null, val interval: Output<Int>? = null, val ispCities: Output<List<SiteMonitorIspCityArgs>>? = null, val optionsJson: Output<String>? = null, val taskName: Output<String>? = null, val taskType: Output<String>? = null) : ConvertibleToJava<SiteMonitorArgs>

This resource provides a site monitor resource and it can be used to monitor public endpoints and websites. Details at https://www.alibabacloud.com/help/doc-detail/67907.htm

NOTE: Available since v1.72.0.

Example Usage

Basic Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cms.SiteMonitor;
import com.pulumi.alicloud.cms.SiteMonitorArgs;
import com.pulumi.alicloud.cms.inputs.SiteMonitorIspCityArgs;
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 basic = new SiteMonitor("basic", SiteMonitorArgs.builder()
.address("http://www.alibabacloud.com")
.interval(5)
.ispCities(SiteMonitorIspCityArgs.builder()
.city("546")
.isp("465")
.build())
.taskName("tf-example")
.taskType("HTTP")
.build());
}
}

Import

Cloud Monitor Service Site Monitor can be imported using the id, e.g.

$ pulumi import alicloud:cms/siteMonitor:SiteMonitor example <id>

Constructors

Link copied to clipboard
fun SiteMonitorArgs(address: Output<String>? = null, alertIds: Output<List<String>>? = null, interval: Output<Int>? = null, ispCities: Output<List<SiteMonitorIspCityArgs>>? = null, optionsJson: Output<String>? = null, taskName: Output<String>? = null, taskType: Output<String>? = null)

Functions

Link copied to clipboard
open override fun toJava(): SiteMonitorArgs

Properties

Link copied to clipboard
val address: Output<String>? = null

The URL or IP address monitored by the site monitoring task.

Link copied to clipboard
val alertIds: Output<List<String>>? = null

The IDs of existing alert rules to be associated with the site monitoring task.

Link copied to clipboard
val interval: Output<Int>? = null

The monitoring interval of the site monitoring task. Unit: minutes. Valid values: 1, 5, 15, 30 and 60. Default value: 1. NOTE: From version 1.207.0, interval can be set to 30, 60.

Link copied to clipboard
val ispCities: Output<List<SiteMonitorIspCityArgs>>? = null

The detection points in a JSON array. For example, [{"city":"546","isp":"465"},{"city":"572","isp":"465"},{"city":"738","isp":"465"}] indicates the detection points in Beijing, Hangzhou, and Qingdao respectively. You can call the DescribeSiteMonitorISPCityList operation to query detection point information. If this parameter is not specified, three detection points will be chosen randomly for monitoring. See isp_cities below.

Link copied to clipboard
val optionsJson: Output<String>? = null

The extended options of the protocol of the site monitoring task. The options vary according to the protocol.

Link copied to clipboard
val taskName: Output<String>? = null

The name of the site monitoring task. The name must be 4 to 100 characters in length. The name can contain the following types of characters: letters, digits, and underscores.

Link copied to clipboard
val taskType: Output<String>? = null

The protocol of the site monitoring task. Currently, site monitoring supports the following protocols: HTTP, PING, TCP, UDP, DNS, SMTP, POP3, and FTP.