This example assumes you have previously completed the following examples:
- Create an Azure Resource Group
- Create an Azure Front Door Profile
- Create an Azure Front Door Endpoint
- Create an Azure Front Door Origin Group
- Create an Azure App Service Plan
- Deploy a managed JavaSE Spring Boot application
- Deploy a managed JavaSE Quarkus application
- Add origins to an Azure Front Door Origin Group
We need to add a route to our Front Door to map the endpoint to the origin group. Use the following command line below:
az afd route create \
--resource-group $RESOURCE_GROUP \
--profile-name $AFD_PROFILE_NAME \
--endpoint-name $AFD_ENDPOINT_NAME \
--forwarding-protocol MatchRequest \
--route-name route \
--https-redirect Enabled \
--origin-group $AFD_ORIGIN_GROUP_NAME \
--supported-protocols Http Https \
--link-to-default-domain Enabled
The next step is to get the endpoint and browse to it.To get the endpoint Use the following command line:
az afd endpoint show --resource-group $RESOURCE_GROUP --profile-name $AFD_PROFILE_NAME --endpoint-name $AFD_ENDPOINT_NAME --query hostName --output tsv
Do NOT forget to remove the resources once you are done running the example.
1m