Pools
resource cloudflare_load_balancer_pool
required
optional
The latitude of the data center containing the origins used in this pool in decimal degrees. If this is set, longitude must also be set.
The longitude of the data center containing the origins used in this pool in decimal degrees. If this is set, latitude must also be set.
The ID of the Monitor Group to use for checking the health of origins within this pool.
A list of regions from which to run health checks. Null means every Cloudflare data center.
Whether to enable (the default) or disable this pool. Disabled pools will not receive traffic and are excluded from health checks. Disabling a pool will cause any load balancers using it to failover to the next pool (if any).
The minimum number of origins that must be healthy for this pool to serve traffic. If the number of healthy origins falls below this number, the pool will be marked unhealthy and will failover to the next available pool.
This field is now deprecated. It has been moved to Cloudflare's Centralized Notification service https://developers.cloudflare.com/fundamentals/notifications/. The email address to send health status notifications to. This can be an individual mailbox or a mailing list. Multiple emails can be supplied as a comma delimited list.
cloudflare_load_balancer_pool
resource "cloudflare_load_balancer_pool" "example_load_balancer_pool" {
account_id = "023e105f4ecef8ad9ca31a8372d0c353"
name = "primary-dc-1"
origins = [{
address = "0.0.0.0"
enabled = true
header = {
host = ["example.com"]
}
name = "app-server-1"
port = 0
virtual_network_id = "a5624d4e-044a-4ff0-b3e1-e2465353d4b4"
weight = 0.6
}]
description = "Primary data center - Provider XYZ"
enabled = false
latitude = 0
load_shedding = {
default_percent = 0
default_policy = "random"
session_percent = 0
session_policy = "hash"
}
longitude = 0
minimum_origins = 0
monitor = "monitor"
monitor_group = "monitor_group"
notification_email = "someone@example.com,sometwo@example.com"
notification_filter = {
origin = {
disable = true
healthy = true
}
pool = {
disable = true
healthy = false
}
}
origin_steering = {
policy = "random"
}
}
data cloudflare_load_balancer_pool
computed
This field shows up only if the pool is disabled. This field is set with the time the pool was disabled at.
Whether to enable (the default) or disable this pool. Disabled pools will not receive traffic and are excluded from health checks. Disabling a pool will cause any load balancers using it to failover to the next pool (if any).
The latitude of the data center containing the origins used in this pool in decimal degrees. If this is set, longitude must also be set.
The longitude of the data center containing the origins used in this pool in decimal degrees. If this is set, latitude must also be set.
The minimum number of origins that must be healthy for this pool to serve traffic. If the number of healthy origins falls below this number, the pool will be marked unhealthy and will failover to the next available pool.
The ID of the Monitor Group to use for checking the health of origins within this pool.
A short name (tag) for the pool. Only alphanumeric characters, hyphens, and underscores are allowed.
This field is now deprecated. It has been moved to Cloudflare's Centralized Notification service https://developers.cloudflare.com/fundamentals/notifications/. The email address to send health status notifications to. This can be an individual mailbox or a mailing list. Multiple emails can be supplied as a comma delimited list.
cloudflare_load_balancer_pool
data "cloudflare_load_balancer_pool" "example_load_balancer_pool" {
account_id = "023e105f4ecef8ad9ca31a8372d0c353"
pool_id = "17b5962d775c646f3f9725cbc7a53df4"
}
data cloudflare_load_balancer_pools
optional
cloudflare_load_balancer_pools
data "cloudflare_load_balancer_pools" "example_load_balancer_pools" {
account_id = "023e105f4ecef8ad9ca31a8372d0c353"
monitor = "monitor"
}