Skip to main content
Loading
Version: Operator 4.0.0

Use Helm to deploy an Aerospike Backup Service on Kubernetes

danger

AKO version 4.x or later does not support Aerospike Backup Service version 2.x. Upgrade to Aerospike Backup Service v3.0.0 or later. See Upgrade ABS for more information.

Breaking changes in Aerospike Backup Service Helm chart version 4.0.0:

  • It no longer creates the service account aerospike-backup-service. Create the service account before deploying/upgrading the ABS by following this step.

Requirements

Before deploying your Aerospike Backup Service (ABS) using Helm, install AKO on your Kubernetes cluster using either:

Install and deploy

We recommend using one ABS deployment per Aerospike cluster.

  1. Create service account

    Run the following command to create the ABS service account in the namespace where ABS is deployed.

    kubectl create serviceaccount aerospike-backup-service -n aerospike
    note

    You can use a different service account name. Refer to the ABS CR file to set the service account name.

  2. Configure S3 backup storage (optional)

    ABS supports S3 compatible storage as well as local storage for backups. If you use S3 compatible storage, add the credentials or roles to the ABS values.yaml file so ABS can connect to the remote storage.

    Create a Kubernetes secret with the S3 credentials.

    kubectl -n aerospike create secret generic aws-secret --from-file=PATH_TO_AWS_CREDENTIALS

    See the AWS documentation for the format of the credentials file.

    Mount the aws-secret secret in the ABS pod by adding the secrets field in the ABS Helm chart values.yaml.

    secrets:
    - secretName: aws-secret
    volumeMount:
    name: aws-secret
    mountPath: /root/.aws/credentials
    subPath: credentials
  3. Add the Helm repository to get the Helm charts.

    helm repo add aerospike https://aerospike.github.io/aerospike-kubernetes-enterprise

    If the Helm repository is already added, update the index:

    helm repo update
  4. Prepare values.yaml for ABS.

    Create a custom values.yaml file with your required configurations. The following is an example custom values.yaml file.

    image:
    repository: aerospike/aerospike-backup-service
    tag: "3.0.0"

    backupServiceConfig:
    service:
    http:
    port: 8080
    backup-policies:
    test-policy:
    parallel: 3
    storage:
    local:
    local-storage:
    path: /localStorage
    # s3Storage: # Uncomment below lines to use S3 storage
    # s3-storage:
    # bucket: aerospike-kubernetes-operator-test
    # s3-region: us-east-1
    # s3-profile: default

    #secrets:
    # - secretName: aws-secret
    # volumeMount:
    # name: aws-secret
    # mountPath: /root/.aws/credentials
    # subPath: credentials

    service:
    type: ClusterIP
  5. Deploy ABS.

    Install the Helm chart with custom values.

    helm install aerospikebackupservice-sample aerospike/aerospike-backup-service -f PATH_TO_CUSTOM_YAML_FILE
  6. Verify ABS status.

    Run kubectl get deployment to check that AKO has created the ABS deployment.

    $ kubectl get deployment -n aerospike

    NAME READY UP-TO-DATE AVAILABLE AGE
    aerospikebackupservicesample 1/1 1 1 9s

    Run kubectl get pods to check the pods to confirm the status. This step may take time as the pods provision resources, initialize, and become ready. Wait for the pods to switch to the Running state before you continue.

    $ kubectl get pods -n aerospike

    NAME READY STATUS RESTARTS AGE
    aerospikebackupservicesample-7b7f7b5648-kpfxh 1/1 Running 0 43s

Configurations

For more details on these configurations, see the Aerospike Backup Service Configuration Settings.

NameDescriptionDefault
image.repositoryAerospike backup service container image repositoryaerospike/aerospike-backup-service
image.tagAerospike backup service container image tag3.0.0
customLabelsCustom labels to add on the Aerospike backup service resource{} (nil)
backupServiceConfigAerospike backup service configuration{} (nil)
secretsSecrets to be mounted in the Aerospike backup service pod such as AWS credentials[] (nil)
resourcesAerospike backup service pod resource requirements{} (nil)
serviceKubernetes service configuration for Aerospike backup service{} (nil)
podSpecAerospike backup service pod configuration{} (nil)