import * as core from "@terrascript/core"; export interface HealthCheckArgs extends core.ResourceArgs { /** * (Optional) The minimum number of child health checks that must be healthy for Route 53 to consider t * he parent health check to be healthy. Valid values are integers between 0 and 256, inclusive */ childHealthThreshold?: number | core.NumberOut; /** * (Optional) For a specified parent health check, a list of HealthCheckId values for the associated ch * ild health checks. */ childHealthchecks?: core.Array | core.ArrayOut; /** * (Optional) The name of the CloudWatch alarm. */ cloudwatchAlarmName?: string | core.StringOut; /** * (Optional) The CloudWatchRegion that the CloudWatch alarm was created in. */ cloudwatchAlarmRegion?: string | core.StringOut; /** * (Optional) A boolean value that stops Route 53 from performing health checks. When set to true, Rout * e 53 will do the following depending on the type of health check: */ disabled?: boolean | core.BooleanOut; /** * (Optional) A boolean value that indicates whether Route53 should send the `fqdn` to the endpoint whe * n performing the health check. This defaults to AWS' defaults: when the `type` is "HTTPS" `enable_sn * i` defaults to `true`, when `type` is anything else `enable_sni` defaults to `false`. */ enableSni?: boolean | core.BooleanOut; /** * (Optional) The number of consecutive health checks that an endpoint must pass or fail. */ failureThreshold?: number | core.NumberOut; /** * (Optional) The fully qualified domain name of the endpoint to be checked. */ fqdn?: string | core.StringOut; /** * (Optional) The status of the health check when CloudWatch has insufficient data about the state of a * ssociated alarm. Valid values are `Healthy` , `Unhealthy` and `LastKnownStatus`. */ insufficientDataHealthStatus?: string | core.StringOut; /** * (Optional) A boolean value that indicates whether the status of health check should be inverted. For * example, if a health check is healthy but Inverted is True , then Route 53 considers the health che * ck to be unhealthy. */ invertHealthcheck?: boolean | core.BooleanOut; /** * (Optional) The IP address of the endpoint to be checked. */ ipAddress?: string | core.StringOut; /** * (Optional) A Boolean value that indicates whether you want Route 53 to measure the latency between h * ealth checkers in multiple AWS regions and your endpoint and to display CloudWatch latency graphs in * the Route 53 console. */ measureLatency?: boolean | core.BooleanOut; /** * (Optional) The port of the endpoint to be checked. */ port?: number | core.NumberOut; /** * (Optional) This is a reference name used in Caller Reference */ referenceName?: string | core.StringOut; /** * (Optional) A list of AWS regions that you want Amazon Route 53 health checkers to check the specifie * d endpoint from. */ regions?: core.Array | core.ArrayOut; /** * (Required) The number of seconds between the time that Amazon Route 53 gets a response from your end * point and the time that it sends the next health-check request. */ requestInterval?: number | core.NumberOut; /** * (Optional) The path that you want Amazon Route 53 to request when performing health checks. */ resourcePath?: string | core.StringOut; /** * (Optional) The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing c * ontrol. This is used when health check type is `RECOVERY_CONTROL` */ routingControlArn?: string | core.StringOut; /** * (Optional) String searched in the first 5120 bytes of the response body for check to be considered h * ealthy. Only valid with `HTTP_STR_MATCH` and `HTTPS_STR_MATCH`. */ searchString?: string | core.StringOut; /** * (Optional) A map of tags to assign to the health check. If configured with a provider [`default_tags * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tag * s-configuration-block) present, tags with matching keys will overwrite those defined at the provider * level. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; /** * (Required) The protocol to use when performing health checks. Valid values are `HTTP`, `HTTPS`, `HTT * P_STR_MATCH`, `HTTPS_STR_MATCH`, `TCP`, `CALCULATED`, `CLOUDWATCH_METRIC` and `RECOVERY_CONTROL`. */ type: string | core.StringOut; } export class HealthCheck extends core.Resource { /** * The Amazon Resource Name (ARN) of the Health Check. */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Optional) The minimum number of child health checks that must be healthy for Route 53 to consider t * he parent health check to be healthy. Valid values are integers between 0 and 256, inclusive */ @core.attr(Number) public childHealthThreshold?: number | core.NumberOut; /** * (Optional) For a specified parent health check, a list of HealthCheckId values for the associated ch * ild health checks. */ @core.attr(String, { kind: "array" }) public childHealthchecks?: core.Array | core.ArrayOut; /** * (Optional) The name of the CloudWatch alarm. */ @core.attr(String) public cloudwatchAlarmName?: string | core.StringOut; /** * (Optional) The CloudWatchRegion that the CloudWatch alarm was created in. */ @core.attr(String) public cloudwatchAlarmRegion?: string | core.StringOut; /** * (Optional) A boolean value that stops Route 53 from performing health checks. When set to true, Rout * e 53 will do the following depending on the type of health check: */ @core.attr(Boolean) public disabled?: boolean | core.BooleanOut; /** * (Optional) A boolean value that indicates whether Route53 should send the `fqdn` to the endpoint whe * n performing the health check. This defaults to AWS' defaults: when the `type` is "HTTPS" `enable_sn * i` defaults to `true`, when `type` is anything else `enable_sni` defaults to `false`. */ @core.attr(Boolean, { computed: true }) public enableSni?: boolean | core.BooleanOut; /** * (Optional) The number of consecutive health checks that an endpoint must pass or fail. */ @core.attr(Number, { computed: true }) public failureThreshold?: number | core.NumberOut; /** * (Optional) The fully qualified domain name of the endpoint to be checked. */ @core.attr(String) public fqdn?: string | core.StringOut; /** * The id of the health check */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Optional) The status of the health check when CloudWatch has insufficient data about the state of a * ssociated alarm. Valid values are `Healthy` , `Unhealthy` and `LastKnownStatus`. */ @core.attr(String) public insufficientDataHealthStatus?: string | core.StringOut; /** * (Optional) A boolean value that indicates whether the status of health check should be inverted. For * example, if a health check is healthy but Inverted is True , then Route 53 considers the health che * ck to be unhealthy. */ @core.attr(Boolean) public invertHealthcheck?: boolean | core.BooleanOut; /** * (Optional) The IP address of the endpoint to be checked. */ @core.attr(String) public ipAddress?: string | core.StringOut; /** * (Optional) A Boolean value that indicates whether you want Route 53 to measure the latency between h * ealth checkers in multiple AWS regions and your endpoint and to display CloudWatch latency graphs in * the Route 53 console. */ @core.attr(Boolean) public measureLatency?: boolean | core.BooleanOut; /** * (Optional) The port of the endpoint to be checked. */ @core.attr(Number) public port?: number | core.NumberOut; /** * (Optional) This is a reference name used in Caller Reference */ @core.attr(String) public referenceName?: string | core.StringOut; /** * (Optional) A list of AWS regions that you want Amazon Route 53 health checkers to check the specifie * d endpoint from. */ @core.attr(String, { kind: "array" }) public regions?: core.Array | core.ArrayOut; /** * (Required) The number of seconds between the time that Amazon Route 53 gets a response from your end * point and the time that it sends the next health-check request. */ @core.attr(Number) public requestInterval?: number | core.NumberOut; /** * (Optional) The path that you want Amazon Route 53 to request when performing health checks. */ @core.attr(String) public resourcePath?: string | core.StringOut; /** * (Optional) The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing c * ontrol. This is used when health check type is `RECOVERY_CONTROL` */ @core.attr(String) public routingControlArn?: string | core.StringOut; /** * (Optional) String searched in the first 5120 bytes of the response body for check to be considered h * ealthy. Only valid with `HTTP_STR_MATCH` and `HTTPS_STR_MATCH`. */ @core.attr(String) public searchString?: string | core.StringOut; /** * (Optional) A map of tags to assign to the health check. If configured with a provider [`default_tags * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tag * s-configuration-block) present, tags with matching keys will overwrite those defined at the provider * level. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; /** * (Required) The protocol to use when performing health checks. Valid values are `HTTP`, `HTTPS`, `HTT * P_STR_MATCH`, `HTTPS_STR_MATCH`, `TCP`, `CALCULATED`, `CLOUDWATCH_METRIC` and `RECOVERY_CONTROL`. */ @core.attr(String) public type!: string | core.StringOut; constructor(name: string, args?: HealthCheckArgs) { super(name, "aws_route53_health_check", args); } public override getNamespace(): string { return "aws_route53"; } }