Use this data source to get the list of the Fastly datacenters.
data "fastly_datacenters" "fastly" {}
output "fastly_datacenters_all" {
value = data.fastly_datacenters.fastly
}
output "fastly_datacenters_filtered" {
# get the shield code of "TYO" POP
value = one([for pop in data.fastly_datacenters.fastly.pops : pop.shield if pop["code"] == "TYO"])
}
id
(String) The ID of this resource.pops
(List of Object) A list of all Fastly POPs. (see below for nested schema)pops
Read-Only:
code
(String)group
(String)name
(String)shield
(String)