How to declare Azure Front Door premium in Azure-native?TypeScript
The Azure Front Door (Premium and Standard) uses resources from both the
cdnnamespaces. The main resource is
azure-native.network.FrontDoor, and it connects to back-end pools, routing rules, and front-end endpoints.
Here is an example of how to declare an Azure Front Door Premium instance. This program creates a Front Door with one Backend, one BackendPool, one RoutingRule, and one FrontendEndpoint.
To create this, you are required to provide your own resource group.
This is a simple instance of Front Door. Depending on your requirements,
FrontDoorcan be as complex as your architecture needs.
Each of the resources created above represents what can be visualized as tabs in the Azure Portal skin for Front Door. Those resources include:
- Backend: Represents a physical endpoint where a Front Door can route traffic to. This can be an App service, a CIDR block, an API Management service, or a storage account, for example.
- Backend Pool: Is a logical group of backends that a given Route (Routing Rule) can route traffic to.
- Routing Rules: Define a combination of a pattern that a frontendListener monitors and an action to take when a route matches the path.
- Frontend Endpoint: Can be any custom domain associated with the Front Door, or the default endpoint (with azurefd.net at the end).
- Health Probes and Load Balancing: These two settings can be associated with the Backend Pool and affect the routing decisions and availability of the endpoints.
Please note that the above code is a simple declarative representation of Front Door resources. The ids and parameters are abstracted for understanding purposes, you need to replace them with valid existing ids and parameters according to your setup.
For full examples and additional details about Azure Front Door configuration and properties, refer to the Azure Front Door Documentation.