1. Tools
  2. Pulsar Operator

Install Pulsar Operator

The Pulsar Operator manages the Pulsar service instances deployed on a Kubernetes cluster. It is built using the Operator SDK, which is part of the Operator Framework.

This document describes how to install and uninstall the Pulsar Operator.

Install Pulsar Operator

This section describes how to install the Pulsar Operator using the pulsar-operator Helm chart. This is the officially supported Helm chart for installing the Pulsar Operator. It provides Customer Resource Definitions (CRDs) and Controllers to manage and run Pulsar clusters in a resilient way.

Prerequisites

  • Install kubectl (v1.16 or higher), compatible with your cluster (+/- 1 minor release from your cluster).
  • Install Helm (v3.0.2 or higher).
  • Prepare a Kubernetes cluster (v1.16 or higher).

Steps

To install the Pulsar Operator, follow these steps.

  1. Add the StreamNative chart repository.

    helm repo add streamnative https://charts.streamnative.io
    helm repo update
    
  2. Create a Kubernetes namespace.

    kubectl create namespace <k8s-namespace>
    

    You can also skip this step if you specify a Kubernetes namespace via the -- create-namespace <k8s-namespace> option when you install the Pulsar Operator.

  3. Install the Pulsar Operator using the pulsar-operator Helm chart.

    helm install pulsar-operators --namespace <k8s-namespace> streamnative/pulsar-operator
    
  4. Verify that the Pulsar Operator is installed successfully.

    kubectl get po -n <k8s-namespace>
    

    Expected outputs:

    NAME                                                              READY   STATUS    RESTARTS   AGE
    pulsar-operators-bookkeeper-controller-manager-854765f948-lzzbw   1/1     Running   0          22s
    pulsar-operators-pulsar-controller-manager-74ff6f64b5-rwl7t       1/1     Running   0          22s
    pulsar-operators-zookeeper-controller-manager-5fdbc656d8-rr6pj    1/1     Running   0          22s
    

Uninstall Pulsar Operator

To uninstall the Pulsar Operator, execute this command.

helm uninstall pulsar-operator -n <k8s-namespace>

CRDs installed during Helm chart installation are not automatically removed when uninstalling the Helm chart. Currently, the pulsar-operator Helm chart installs the following CRDs, which need to be deleted manually if no longer needed.

  • bookkeeperclusters.bookkeeper.streamnative.io
  • pulsarbrokers.pulsar.streamnative.io
  • pulsarconnections.pulsar.streamnative.io
  • pulsarnamespaces.pulsar.streamnative.io
  • pulsarproxies.pulsar.streamnative.io
  • pulsartenants.pulsar.streamnative.io
  • pulsartopics.pulsar.streamnative.io
  • zookeeperclusters.zookeeper.streamnative.io
Previous
Overview