Kubernetes Cluster Setup

Before deploying Akri, you must have a Kubernetes cluster (v1.16 or higher) running with kubectl and Helm installed. Akri is Kubernetes native, so it should run on most Kubernetes distributions. This document provides cluster setup instructions for the three Kubernetes distributions that all of our end-to-end tests run on.

Note: All nodes must be Linux on amd64, arm64v8, or arm32v7.

Install Kubernetes Distribution

  1. Reference Kubernetes documentation for instructions on how to install Kubernetes. See Akri's release notes to see what versions of Kubernetes Akri has been tested on.

  2. Install Helm for deploying Akri.

     sudo apt install -y curl
     curl -L https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash

Note: To enable workloads on a single-node cluster, remove the master taint.

kubectl taint nodes --all node-role.kubernetes.io/master-

Configure crictl

Akri depends on crictl to track some Pod information. In order to use it, the Agent must know where the container runtime socket lives. This can be configured with Akri's Helm chart either directly by setting agent.host.containerRuntimeSocket or indirectly by specifying the Kubernetes distribution that is being used (kubernetesDistro=k3s|microk8s|k8s). If a distribution is specified, then the appropriate default will be used. If no distribution or runtime is specified, the k8s default is used.

Akri recommends setting this choice as an AKRI_HELM_CRICTL_CONFIGURATION environment variable and then adding the variable to each Akri installation like so:

  helm install akri akri-helm-charts/akri \
     $AKRI_HELM_CRICTL_CONFIGURATION

The following are the recommended settings based on Kubernetes distribution.

To use the default standard Kubernetes container runtime socket /run/containerd/containerd.sock, set k8s as the distribution.

export AKRI_HELM_CRICTL_CONFIGURATION="--set kubernetesDistro=k8s"

Last updated