Kubernetes operators using
KUDO, the Kubernetes Universal Declarative Operator. KUDO provides a declarative approach to building production-grade Kubernetes Operators covering the entire application lifecycle.
Run the following three commands to
kubectl create -f https://raw.githubusercontent.com/kudobuilder/kudo/v0.5.0/docs/deployment/00-prereqs.yaml kubectl create -f https://raw.githubusercontent.com/kudobuilder/kudo/v0.5.0/docs/deployment/10-crds.yaml kubectl create -f https://raw.githubusercontent.com/kudobuilder/kudo/842c7f19a0a361751f0dab330faf3be147c9c4b3/docs/deployment/20-deployment.yaml
More on the kudo install at kudo.dev .
Kudo comes with its own
kubectl CLI plugin. On
Mac OS X you can install it using
brew tap kudobuilder/tap brew install kudo-cli
More on the kudo CLI install at kudo.dev .
install and operate kudo operators
Install and operate your first kudo operator using kafka as the sample.
develop kudo operators
kudo operator programming model
As a developer of a kudo operator you have to author three types of
YAML artifacts in the following file folder structure.
operator.yaml params.yaml templates/ <template>.yaml ...
In the following we describe the roles that each of the YAML artifacts plays and what they capture.
The operator file defines the operator behavior.
It has a
name (e.g kafka), and a
Tasks list the resource templates that get applied together.
Plans orchestrate tasks through phases and steps.
Plans consists of one or more
Phases consists of one or more
Steps contain one or more
tasks. Both phases and also steps can be configured with an
execution strategy, either
The params file defines the parameters that can be used to configure an instance created by the operator. A parameter definition has a
display name, and
A template file defines the resources that can be applied by operator tasks. Samples are
stateful set, ... .
unit 1: parameters, templates, tasks, and plans in action
- showcasing the core operator concepts
unit 2: a stateful service
- showcasing stateful set, and headless service templates
- showcasing containers, and init containers
- showcasing persistent volumes
- showcasing instance update, showing scaling
unit 3: update and upgrade plans
- showcasing update and upgrade Plans
- showcasing controlled parameter updates
unit 4: custom plans
- showcasing backup and restore