---
title: "Use Helm to deploy Aerospike Backup Service on Kubernetes"
description: "Deploy Aerospike Backup Service on Kubernetes using Helm, including service account and S3 storage configuration."
---

# Use Helm to deploy Aerospike Backup Service on Kubernetes

> For the complete documentation index see: [llms.txt](https://aerospike.com/docs/llms.txt)
> 
> All documentation pages available in markdown.

::: caution
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](https://aerospike.com/docs/kubernetes/tools/backup/upgrade-backup-service) for more information.

Breaking changes when upgrading from an Aerospike Backup Service Helm chart version earlier than 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](#install-and-deploy) step.
:::

## Requirements

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

-   [OLM](https://aerospike.com/docs/kubernetes/4.4.x/install/olm)
-   [Helm](https://aerospike.com/docs/kubernetes/4.4.x/install/helm)

## Install and deploy

We recommend using one ABS deployment per Aerospike cluster.

1.  Create the ABS service account.
    
    Create the service account in the namespace where ABS is intended to be deployed.
    
    Terminal window
    
    ```shell
    kubectl create serviceaccount aerospike-backup-service -n aerospike
    ```
    
    ::: note
    You can use a different service account name. Refer to the [ABS CR file](https://aerospike.com/docs/kubernetes/4.4.x/tools/backup/backup-service-configuration) to set the service account name.
    :::
    
2.  Configure S3 backup storage (optional)
    
    ABS supports S3-compatible storage and 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.
    
    -   [S3 Static Credentials (Kubernetes Secrets)](#tab-panel-3701)
    -   [IAM Roles for Service Accounts (IRSA)](#tab-panel-3702)
    
    Create a Kubernetes secret with the S3 credentials.
    
    Terminal window
    
    ```shell
    kubectl -n aerospike create secret generic aws-secret --from-file=PATH_TO_AWS_CREDENTIALS
    ```
    
    See the [AWS documentation](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html) 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.
    
    ```yaml
    secrets:
    
      - secretName: aws-secret
    
        volumeMount:
    
          name: aws-secret
    
          mountPath: /home/absuser/.aws/credentials
    
          subPath: credentials
    ```
    
    Create and attach an IAM role with the required permissions to the ABS service account `aerospike-backup-service`. Change the service account and role ARN in the following example to the values you created.
    
    Terminal window
    
    ```shell
    kubectl annotate serviceaccount -n aerospike aerospike-backup-service eks.amazonaws.com/role-arn=arn:aws:iam::123456789012:role/MyServiceRole
    ```
    
    See the IRSA documentation for more information on [IAM roles for service accounts](https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html).
    
3.  Add the Helm repository to get the Helm charts.
    
    Terminal window
    
    ```shell
    helm repo add aerospike https://aerospike.github.io/aerospike-kubernetes-enterprise
    ```
    
    If the Helm repository is already added, update the index:
    
    Terminal window
    
    ```shell
    helm repo update
    ```
    
4.  Prepare `values.yaml` for ABS.
    
    Create a custom `values.yaml` file with your required configurations. Set `image.tag` to a tag from the [Aerospike Backup Service image repository](https://hub.docker.com/r/aerospike/aerospike-backup-service) (for example, `3.5.0`). The following is an example custom `values.yaml` file.
    
    ```yaml
    image:
    
      repository: aerospike/aerospike-backup-service
    
      tag: "3.5.0"
    
    backupServiceConfig:
    
      service:
    
        http:
    
          port: 8080
    
      backup-policies:
    
        test-policy:
    
          parallel: 3
    
      storage:
    
        local:
    
          local-storage:
    
            path: /tmp/localStorage
    
    #    s3Storage: # Uncomment the following 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: /home/absuser/.aws/credentials
    
    #      subPath: credentials
    
    service:
    
      type: ClusterIP
    ```
    
5.  Deploy ABS.
    
    Install the Helm chart with custom values.
    
    Terminal window
    
    ```shell
    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.
    
    Terminal window
    
    ```shell
    kubectl get deployment -n aerospike
    ```
    
    ```text
    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.
    
    Terminal window
    
    ```shell
    kubectl get pods -n aerospike
    ```
    
    ```text
    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](https://aerospike.com/docs/kubernetes/4.4.x/tools/backup/backup-service-configuration).

| Name | Description | Default |
| --- | --- | --- |
| `image.repository` | Aerospike backup service container image repository | `aerospike/aerospike-backup-service` |
| `image.tag` | Aerospike backup service container image tag | `3.5.0` |
| `customLabels` | Custom labels to add on the Aerospike backup service resource | `{}` (nil) |
| `backupServiceConfig` | Aerospike backup service configuration | `{}` (nil) |
| `secrets` | Secrets to be mounted in the Aerospike backup service pod such as AWS credentials | `[]` (nil) |
| `resources` | Aerospike backup service pod resource requirements | `{}` (nil) |
| `service` | Kubernetes service configuration for Aerospike backup service | `{}` (nil) |
| `podSpec` | Aerospike backup service pod configuration | `{}` (nil) |