> [!NOTE]
> **Note:** Minibroker is not an officially supported part of Kf.

The following steps will guide you through installing a service broker called
[Minibroker](https://github.com/kubernetes-sigs/minibroker).
Minibroker adapts Helm charts into brokered services. When a service is provisioned,
the Helm chart is applied to the same namespace as the apps it will be bound to.

Minibroker provides the following services by default:

- MariaDB
- MongoDB
- MySQL
- PostgreSQL
- Redis

## Before you begin

You will need a cluster with Kf installed and access
to the Kf CLI.

Additionally, you will need the following software:

- **`helm`** : Follow [these instructions](https://helm.sh/docs/intro/install/) to install the `helm` CLI.

## Install Minibroker

1. Check that Helm is at least version 3 by running:

   ```bash
   helm version
   ```

   The output should look similar to the following:

       version.BuildInfo{Version:"v3.0.0", GitCommit:"e29ce2a54e96cd02ccfce88bee4f58bb6e2a28b6", GitTreeState:"clean", GoVersion:"go1.13.4"}

2. Add the Minibroker Helm chart repository:

   ```bash
   helm repo add minibroker "https://minibroker.blob.core.windows.net/charts"
   ```

   Helm will report that the repository was added:

       "minibroker" has been added to your repositories

3. Create a Kubernetes namespace for the broker:

   ```bash
   kubectl create namespace minibroker
   ```
4. Install Minibroker into the Kubernetes cluster:

   ```bash
   helm install minibroker minibroker/minibroker \
     --namespace minibroker \
     --set "deployServiceCatalog=false"
   ```
5. Register the broker with Kf:

   ```bash
   kf create-service-broker minibroker \
     "user" \
     "pass" \
     "http://minibroker-minibroker.minibroker.svc.cluster.local"
   ```

   > [!NOTE]
   > **Note:** It may take several minutes for the broker to be reachable.

## Confirm broker installation

Run `kf marketplace`. You should see output similar to:

    $ kf marketplace

    5 services can be used in Space "default", use the --service flag to list the plans for a service

    Broker      Name        Space      Status  Description
    minibroker  mariadb                Active  Helm Chart for mariadb
    minibroker  mongodb                Active  Helm Chart for mongodb
    minibroker  mysql                  Active  Helm Chart for mysql
    minibroker  postgresql             Active  Helm Chart for postgresql
    minibroker  redis                  Active  Helm Chart for redis

## Removal

Run the following to remove Minibroker:

```bash
kf delete-service-broker minibroker
helm uninstall minibroker --namespace minibroker
kubectl delete namespace minibroker
```