Operator SDK
Operator SDK is a popular way to create a Kubernetes operator. The Operator Hub is the official repository to find operators built using Operator SDK.
Before you Begin
To run an SDK Operator workload beyond the standard workload prerequisties, you will need:
- Operator Lifecycle Manager (OLM) service running in the cluster
The details for its installation are part of the install instructions when searching on Operator Hub.
Run an SDK Operator Workload
CockroachDB is used as an example. Search Operator Hub for “cockroach db” results in the operators detail page. Pressing the “Install” button reveals the installation instructions which include the OLM instructions. Only one OLM is needed for a cluster. The details provided are as follows:
Installation of OLM
curl -sL https://github.com/operator-framework/operator-lifecycle-manager/releases/download/0.16.1/install.sh | bash -s 0.16.1
Installation of the Operator
kubectl create -f https://operatorhub.io/install/cockroachdb.yaml
Some of the SDK Operators are based on Helm. This allows for the configuration of operator configuration values using helm values files. Details are provided on the operator landing page. CockroachDB Operator page provides an example.