Skip to content

Preflight

Before using the Helm charts you need:

  • to build your kdb+ containers, and push them to a container registry if using a public cloud
  • access to a Kubernetes cluster (cluster-admin)
  • the Kubectl tool
  • a Helm client
Windows support

This stack, including a local Kubernetes development via Minikube or KinD, is supported on Windows, but requires administrator access.

Building containers

Build and tag your containers with QPacker.

cd containers/
qp build

Once containers images have been successfully built, use qp to tag and push your images to a Docker repository

qp tag gcr.io/cloudpak/tp 1.2.3
qp push  gcr.io/cloudpak/tp 1.2.3

After a release of a new image tag, ensure that image.tag of the relevant component is updated within the values.yaml.

qp build instructions are defined within the containers/qp.json file.

{
  "tp": {
    "depends": [ "qlog" ],
    "entry": [ "src/process/tp.q" ]
  },
...
}

A version of qLog.qpk has been committed to the containers directory, and is extracted by qp on qp build.

Supported platforms

Helm should work with any version of Kubernetes, including the major public clouds and on-premise installs.

Local development (Minikube/KinD)

You can run these charts in a local Minikube (or KinD, etc.) environment.

Deploying locally

When deploying locally, remember to switch to the Minikube Docker context before building your containers with QPacker.

This step is unnecessary if using a single Docker daemon, e.g. KindD.

eval $(minikube docker-env)

On some versions of Linux, you may need to mount the containers directory to Minikube. The best way is to use the minikube command from within the containers directory:

minikube mount $(pwd):$(pwd)

Leave that shell open and the command running, as instructed.

Build the kdb+ container and helm install the charts.

Amazon Elastic Kubernetes Cluster (EKS)

  1. Create your EKS cluster.

  2. Obtain the credentials for the target cluster, updating the cluster name:

      aws eks update-kubeconfig --name kx
    

Azure Kubernetes Service (AKS)

  1. Create your AKS cluster.
  2. Obtain the credentials for the AKS cluster, updating the cluster name.

      az aks get-credentials --name kx --resource-group kx-demo
    

Google Kubernetes Engine (GKE)

  1. Create a cluster if necessary.
  2. Obtain the credentials for the target cluster, updating the cluster name and region:

      gcloud container clusters get-credentials kdb+ --region us-central1
    

Then

  1. Build the kdb+ containers.
  2. Update the image repo in your values.yaml, or use

    --set images.repository=
    

    to configure your container registry, e.g. ECR, ACR, GCR.

  3. Deploy the Helm charts.

Kubectl context and namespace

Kubectl can be configured with access to multiple cluster and namespaces. When calling kubectl or using Helm, current-context and namespace are used to determine which cluster to interact with.

Contexts can be viewed:

kubectl config get-contexts

Selecting a context:

kubectl config use-context my-cluster-name

View all namespace:

kubectl get namespace

Creating a namespace:

kubectl create namespace myns
kubectl config set-context --current --namespace=myns

Kubectl context and configuration