Docker announces collaboration with Azure

Docker today announced that it has extended its strategic collaboration with Microsoft to simplify code to cloud application development for developers and development teams by more closely integrating with Azure Container Instances (ACI). 

Docker and Microsoft’s collaboration extends to other products as well. Docker will add integrations for Visual Studio Code, Microsoft’s widely used free code editor, to let developers who use the tool deploy their code as containers faster. After this collaboration, you can login directly to Azure from Docker CLI, then you can select Docker context. If we have resource group, you can select it or you can create a new resource group. Then, you can run individual or multiple containers using Docker Compose.
docker login Azure

docker context create aci-westus aci --aci-subscription-id xxx --aci-resource-group yyy --aci-location westus

docker context use aci-westus
Tighter integration between Docker and Microsoft developer technologies provides the following productivity benefits:

  1. Easily log into Azure directly from the Docker CLI
  2. Trigger an ACI cloud container service environment to be set up automatically with easy to use defaults and no infrastructure overhead
  3. Switch from a local context to a cloud context to run applications quickly and easily
  4. Simplifies single container and multi-container application development via the Compose specification allowing a developer to invoke fully Docker compatible commands seamlessly for the first time natively within a cloud container service
  5. Provides developer teams the ability to share their work through Docker Hub by sharing their persistent collaborative cloud development environments where they can do remote pair programming and real-time collaborative troubleshooting
For more information & developers can sign up for Docker Desktop & VS Code beta here.

Azure Front Door Deployment using ARM Template

In this article, we will provision Azure Front Door using Arm Template. I have already created two Azure Web Apps which are running in two different regions i.e West Europe & South East Asia region. We will create & configure Azure Front Door to direct the traffic to these web apps.

Follow the below steps to deploy Azure Front Door:

  1. Download this git repo and fill the parameters in azuredeploy.parameters.json as shown below:
  2. {
    \"$schema\": \"https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#\",
    \"contentVersion\": \"1.0.0.0\",
    \"parameters\": {
    \"frontDoorName\": {
    \"value\": \"ashishfrontdoortest\"
    },
    \"dynamicCompression\": {
    \"value\": \"Enabled\"
    },
    \"backendPools1\": {
    \"value\": {
    \"name\": \"backendpool1\",
    \"backends\": [
    {
    \"address\": \"ashishtest1.azurewebsites.net\",
    \"httpPort\": 80,
    \"httpsPort\": 443,
    \"weight\": 50,
    \"priority\": 1,
    \"enabledState\": \"Enabled\"
    },
    {
    \"address\": \"ashishtest2.azurewebsites.net\",
    \"httpPort\": 80,
    \"httpsPort\": 443,
    \"weight\": 50,
    \"priority\": 2,
    \"enabledState\": \"Enabled\"
    }
    ]
    }
    }
    }
    }

  3. Run the below PowerShell command to provision the AFD.
Login-AzureRmAccount
$ResourceGroupName = \"\" #Enter Resource group Name
$AzuredeployFileURL=\"\" #File path of azuredeploy.json
$AzuredeployParametersFile = \"\" #File path of azuredeploy.parameters.json
Set-AzureRmContext -SubscriptionId \"\" #Subscription ID
New-AzureRmResourceGroupDeployment -ResourceGroupName $ResourceGroupName -TemplateFile $AzuredeployFileURL -TemplateParameterFile $AzuredeployParametersFile
Once Azure front Door is deployed, go to browser and navigate the Frontend host URL of AFD. Your request will be routed to Azure Web App.
Go to Azure Portal to check the AFD configuration. Click on the Front Door Designer from left navigation bar and open Frontends/domains.

Here you can enable SESSION AFFINITY & WEB APPLICATION FIREWALL
Now open backend pools as illustrated below. Here you can update your backend pools configuration.
Last section is routing rule which maps your frontend host and a matching URL path pattern to a specific backend pool.
Here you can configure URL rewrite, Caching, Dynamic compression, Query String caching behavior etc.