Complete the code to create an Azure Front Door resource with a global routing method.
resource "azurerm_frontdoor" "example" { name = "example-frontdoor" resource_group_name = "example-rg" routing_method = "[1]" }
The Latency routing method routes traffic to the backend with the lowest latency, which is common for Azure Front Door to optimize performance globally.
Complete the code to define a backend pool with health probes enabled.
backend_pool {
name = "backendPool1"
load_balancing_name = "loadBalancingSettings1"
health_probe_name = "[1]"
}The healthProbeSettings1 is the correct name for the health probe configuration referenced in the backend pool.
Fix the error in the frontend endpoint configuration by completing the missing protocol.
frontend_endpoint {
name = "frontendEndpoint1"
host_name = "example.azurefd.net"
session_affinity_enabled = true
session_affinity_ttl_seconds = 60
web_application_firewall_policy_link_id = null
custom_https_configuration {
certificate_source = "FrontDoor"
protocol_type = "[1]"
}
}The Https protocol_type enables secure HTTPS traffic for the frontend endpoint.
Fill both blanks to configure a routing rule that forwards traffic from the frontend to the backend pool.
routing_rule {
name = "routingRule1"
frontend_endpoints = ["[1]"]
accepted_protocols = ["[2]"]
route_configuration {
forwarding_configuration {
backend_pool_name = "backendPool1"
}
}
}The frontendEndpoint1 is the correct frontend endpoint name, and Https is the accepted protocol for secure traffic.
Fill all three blanks to define a health probe with interval, path, and protocol settings.
health_probe_settings {
name = "healthProbeSettings1"
interval_in_seconds = [1]
path = "[2]"
protocol = "[3]"
}The health probe checks every 30 seconds, uses the path /healthcheck, and the Http protocol for the probe.