Deploy Azure CDN in existing Sitecore environment using Arm Template

In this article, we will deploy Azure CDN in existing Sitecore XP environment using Powershell & Arm template.

Refer the below steps to deploy Azure CDN:

1.      Download Azure CDN WDP from dev.sitecore.netand upload the WDP in Azure Storage blob container.
Once it is uploaded, you will find two topology XP & XM. I have selected CDN XP topology for this demo. Then, create a SAS token & save it.

2.      Create a parameters.json file as shown below:

{
\"$schema\": \"https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#\",
\"contentVersion\": \"1.0.0.0\",
\"parameters\": {
\"cdWebAppName\": {
\"value\": \"<>\"
},
\"cdnSKU\": {
\"value\": \"<>\"
},
\"cdnMsDeployPackageUrl\": {
\"value\": \"<>\"
}
}
}

Fill the ARM template parameter
cdWebAppName
Name of CD instance
cdnSKU
Premium_Verizon, Standard_Verizon, Standard_Akamai, Standard_Microsoft
cdnMsDeployPackageUrl
SAS token of CDN WDP
3.      Run the below PowerShell command:
Login-AzAccount

$ResourceGroupName = \"<<Enter Resource group name"

$AzuredeployFileURL=\"https://raw.githubusercontent.com/Sitecore/Sitecore-Azure-Quickstart-Templates/master/CDN%201.0.0/xp/azuredeploy.json\"

$AzuredeployParametersFile = \"<<path of above created parameters.json file"

Set-AzContext -Subscription “<>”

New-AzResourceGroupDeployment -ResourceGroupName $ResourceGroupName -TemplateUri $AzuredeployFileURL -TemplateParameterFile $AzuredeployParametersFile -Verbose

4.      Once the script is executed successfully, go to CD instance & you can see CDN.config file inside AppConfig/Include/CDN folder which consists of below settings:
  • Media.AlwaysIncludeServerUrl
  • Media.MediaLinkServerUrl
  • Media.AlwaysAppendRevision
  • MediaResponse.Cacheability
  • MediaResponse.MaxAge

Copy Data from Azure Data Lake Gen 1 to Gen 2 using Azure Data Factory

Today, we will discuss how to use Azure Data factory to copy data from Azure Data Lake Gen1 into Data Lake Gen2.

Prerequisites:

  1. Azure Data Lake Gen1
  2. Data Factory
  3. Azure storage with Data Lake Gen2 enabled

Refer the below steps to copy your data:

  1. Open your Azure portal and go to Data Factory then click on Author & Monitor.
  2. It will open a Data Integration Application in new tab. Now click on Copy Data.copy2
  3. Fill the details in the Properties page and click Nextcopy3
  4. Select the source, then Create a new connection for Data Lake Gen1copy4
  5. Fill out the required parameters. You can use either Service Principal or Managed Identity for Azure resources to authenticate your Azure Data Lake Storage Gen1.copy5
  6. Test the connection, then click Createcopy6
  7. Select your folder in the Dataset as shown belowcopy7
  8. Select the destination & create a new connection for ADLS Gen2.copy11
  9. Fill out the required parameters. You can use either Service Principal or Managed Identity for Azure resources to authenticate your Azure Data Lake Storage Gen1copy8
  10. Test the connection, then click Create
  11. Select the destination & select the folder in the Dataset then click Next
  12. Check and Verify the Summary, then click Nextcopy9
  13. Pipeline will be executed right away.
  14. Monitor the Status
  15. Navigate to the Monitor tab, and see the progresscopy10
  16. You can also view more details by viewing the Activity Runs and view Details

As always do let us know if you have questions or comments using the comments section below!