Walkthrough: Installing Data Exchange Framework in Azure Kubernetes Service

Abstract

How to install Data Exchange Framework in a container environment using Azure Kubernetes Service.

You can install Data Exchange Framework (DEF) in a container environment using Azure Kubernetes Service (AKS).This walkthrough describes how to:

  • Push images to Azure

  • Prepare configuration files for deployment

  • Deploy the containers

To push the image files for DEF to Azure:

  1. You must prepare the installation files and images as explained in Walkthrough: Preparing to install Data Exchange Framework in a container environment.

  2. Tag the images with the docker tag command. For example:

    docker tag sitecore-def-xp0-assets:6.0.0.01525.109-10.0.19042.804-2009 $registry/experimental/def/sitecore-xp1-cm:sc101def
  3. Push the images to your Azure registry with the docker push command. For example:

    docker push $registry/experimental/def/sitecore-xp1-cm:sc101def

To prepare configuration files in your installation for deployment:

  1. Open the folder where you extracted the Data Exchange Framework container deployment package.

  2. Navigate to the DEF.Asset\k8s\<version> folder, for example, DEF.Asset\k8s\ltsc2019. Copy the overrides subfolder to the Sitecore Experience Platform (SXP) container deployment package, in the k8s\<version> folder (on the same level as the xp1 folder).

  3. In the SXP container deployment package, in each of the overrides\<topology>, and overrides\<topology>\secrets folders, locate the kustomization.yaml file. In each file, update parameters in the bases section with the appropriate folder names for your installation, for example, ../../xp1.

    Note

    The bases parameters contain the placement of the original Sitecore container deployment files that the kustomization.yaml files override.

  4. In each kustomization.yaml file, in the images: section, update the newName and newTag parameters with the values for the images you pushed to the Azure Registry, for example cm, cd, xdbautomationworker, and id.

    Note

    To find the values you require, for example, for the cm image, go to the Azure Container Registry, search for your sitecore-def-xp1-cm image, and take the values from that image.

  5. If you are deploying the XP1 topology, in the overrides\<topology>\secrets folder, in the sitecore-tenant-service-connection-string.txt file, update the connection string details. The file contains an example of the connection string.

Before you deploy the containers to Kubernetes, you must prepare the AKS cluster configuration and deploy the ingress controller. For information on how to do this, see the Installation Guide for Production Environment for Kubernetes, which is available on the Sitecore download page.

To deploy the containers and the necessary Kubernetes components:

  1. Open the Windows console, and navigate to the k8s\<version> folder.

  2. Deploy the secrets:

    • If you are using the XP1 topology, run the following command:

      kubectl apply -k ./overrides/<topology>/secrets/
    • If you are using the XM1 topology, run the following command:

      kubectl apply -k ./<topology>/secrets/
  3. Run the external folder. Use this command:

    kubectl apply -k ./<topology>/external/
  4. Wait for all containers to have the status Ok/Running. You can check the status with this command:

    kubectl get pods -o wide
  5. Run the init folder. Use this command:

    kubectl apply -k ./<topology>/init/
  6. Wait for all containers to have the status Completed. You can check the status with this command:

    kubectl get pods -o wide
  7. To create persistent volumes, run this command:

    kubectl apply -f ./<topology>/volumes/azurefile
  8. Run the Sitecore containers with the SFCRM changes. Use this command:

    kubectl apply -k ./overrides/<topology>/
  9. Wait for all containers to have the status Ok/Running. You can check the status with this command :

    kubectl get pods -o wide
  10. Obtain the external IP address. Use this command:

    kubectl get service -l app=nginx-ingress
  11. Update the local host file. For information on how to do this, see the Installation Guide for Production Environment for Kubernetes, which is available on the Sitecore download page.

Note

When the containers have been deployed, rebuild your search indexes.