Load Balancer Monitor
If Cloudflare's Load Balancing to load-balance across multiple origin servers or data centers, you configure one of these Monitors to actively check the availability of those servers over HTTP(S) or TCP.
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.LoadBalancerMonitor;
import com.pulumi.cloudflare.LoadBalancerMonitorArgs;
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 example = new LoadBalancerMonitor("example", LoadBalancerMonitorArgs.builder()
.accountId("f037e56e89293a057740de681ac9abbe")
.description("example tcp load balancer")
.interval(60)
.method("connection_established")
.port(8080)
.retries(5)
.timeout(7)
.type("tcp")
.build());
}
}
Properties
Do not validate the certificate when monitor use HTTPS. Only valid if type
is "http" or "https".
Free text description.
A case-insensitive sub-string to look for in the response body. If this string is not found, the origin will be marked as unhealthy. Only valid if type
is "http" or "https".
The expected HTTP response code or code range of the health check. Eg 2xx
. Only valid and required if type
is "http" or "https".
Follow redirects if returned by the origin. Only valid if type
is "http" or "https".
The HTTP request headers to send in the health check. It is recommended you set a Host header by default. The User-Agent header cannot be overridden.
The RFC3339 timestamp of when the load balancer monitor was last modified.