Kubernetes Operator Development logo

Kubernetes Operator Development

Community
d-padmanabhan
kubernetes-operator-development

Designs, implements, reviews, tests, and operates Kubernetes operators and controllers in Go with Kubebuilder and controller-runtime. Use when defining CRDs, reconciliation loops, status conditions, finalizers, admission webhooks, external-provider controllers, operator upgrades, envtest suites, or controller-runtime cache, retry, and concurrency behavior.

Overview

Publisherd-padmanabhan
Repositoryagent-engineering-handbook
Skill namekubernetes-operator-development
Stars
20
Forks
3
Bundled files
5
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 5 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by d-padmanabhan on GitHub. Read the source before you install it.

Installation

Install the Kubernetes Operator Development AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/d-padmanabhan/agent-engineering-handbook/tree/main/skills/kubernetes-operator-development
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/d-padmanabhan/agent-engineering-handbook.git /tmp/agent-engineering-handbook
mkdir -p .claude/skills
cp -r /tmp/agent-engineering-handbook/skills/kubernetes-operator-development .claude/skills/kubernetes-operator-development
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Kubernetes Operator Development in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Kubernetes Operator Development on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Kubernetes Operator Development is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Kubernetes Operator Development

Mandatory controller and cluster-mutation gates live in the Kubernetes rule (${HANDBOOK_ROOT}/rules/450-kubernetes.mdc). This skill owns the operator design and implementation workflow. Use the Kubernetes containers skill (${HANDBOOK_ROOT}/skills/kubernetes-containers/SKILL.md) for workloads, Helm, Argo CD, and cluster operations.

Core Contract

A custom resource expresses desired intent. Reconciliation observes desired and actual state, performs retry-safe work, and records what was observed. Events only indicate that state might have changed; they are not durable exactly-once commands.

Every design must answer:

  • What is authoritative, and which fields does this controller own?
  • How is each external resource identified and ownership-verified?
  • What happens after duplicate delivery, restart, timeout, or lost response?
  • What is safe to create, adopt, update, retain, and delete?
  • What makes each condition current for the resource generation?
  • What bounds retries, provider calls, concurrency, and tenant impact?
  • How are API and operator upgrades rolled forward and back?

Do not implement a one-shot provisioning workflow inside Reconcile.

Decide Whether to Build an Operator

Prefer an existing Kubernetes API, vendor operator, Crossplane provider, cloud service operator, or composition mechanism when it already provides the required ownership and lifecycle semantics.

Build a custom operator when continuous convergence, a domain-specific API, multi-resource ownership, or custom lifecycle policy creates clear platform value. Do not wrap a trivial remote API call merely to expose it as a CRD.

Design Before Coding

Complete the design review template (${HANDBOOK_ROOT}/skills/kubernetes-operator-development/references/design-review-template.md) before scaffolding implementation. Resolve:

  1. API intent, scope, maturity, and compatibility.
  2. Source of truth and field ownership.
  3. External identity, collision prevention, and adoption proof.
  4. finalizer, deletion, orphan, and recovery behavior.
  5. status conditions and readiness semantics.
  6. retry, rate-limit, timeout, and concurrency budgets.
  7. authentication, Kubernetes RBAC, and provider authorization.
  8. test, upgrade, observability, and rollback evidence.

Use Kubebuilder scaffolding unless repository constraints justify another framework. Verify current Kubebuilder, controller-runtime, Go, and Kubernetes compatibility from official release and support documentation. Do not copy version-specific snippets without checking the repository's pinned versions.

Reconciliation Workflow

Keep Reconcile as orchestration:

  1. Read the primary resource; ignore a true API NotFound.
  2. Handle deletion before normal reconciliation.
  3. Persist the finalizer before creating resources that require cleanup, then return or re-read before continuing.
  4. Validate runtime prerequisites not enforceable at admission.
  5. Observe actual state and verify ownership.
  6. Build desired state and calculate the owned-field delta.
  7. Apply at most the safe, bounded work justified by current observations.
  8. Update status through the status subresource with current conditions and observedGeneration.
  9. Return an error or explicit requeue only under the documented retry policy.

External creation must survive a successful provider mutation followed by a lost response. Prefer a provider idempotency key or conditional create tied to stable operation identity. Observe-before-create is useful but is not by itself race-safe.

Use stable provider identifiers plus verifiable ownership metadata such as the Kubernetes namespace, name, and UID. Status is operational state, not proof of ownership. A deleted and recreated CR has a new UID and must not silently inherit destructive authority over an old external resource.

Detailed runtime guidance: ${HANDBOOK_ROOT}/skills/kubernetes-operator-development/references/reconciliation-runtime.md.

Use controller-runtime's managed cache and event pipeline for normal operators. Declare primary, owned, and dependency watches through the builder, with indexes, mapping functions, and predicates where needed. Do not implement a raw Kubernetes Watch loop or copy a short global resync interval as a substitute for complete event sources and level-based convergence. Use client-go shared informers directly only for a documented lower-level need.

API and Lifecycle

  • Use apiextensions.k8s.io/v1 structural schemas and prune unknown fields.
  • Prefer OpenAPI defaults and validation, then CEL, then admission webhooks only when schema mechanisms cannot express the policy.
  • Model lists and maps with explicit merge semantics where field ownership or Server-Side Apply depends on them.
  • Use metav1.Condition; condition types are positive summaries, reasons are stable machine-readable identifiers, and messages are safe human context.
  • Make destructive deletion and adoption explicit, authorized, auditable, and ownership-checked. Conservative defaults are required for durable data.
  • Treat conversion, storage-version migration, default changes, and rollback as one upgrade contract.

Detailed API guidance: ${HANDBOOK_ROOT}/skills/kubernetes-operator-development/references/api-lifecycle.md.

Provider and Security Boundaries

  • Prefer workload identity. Keep raw credentials outside model, CR spec, status, logs, events, and metrics.
  • Grant Kubernetes and provider permissions per resource and action; avoid wildcard access.
  • Validate provider destinations and identifiers. User-controlled endpoints require scheme, host, redirect, DNS, address, timeout, and response-size controls.
  • Reuse bounded provider clients and transports. Coordinate controller, provider SDK, and HTTP retry layers so delays do not multiply.
  • Apply global and per-tenant concurrency and rate limits. A noisy tenant must not consume the entire controller or provider budget.
  • Do not force Server-Side Apply ownership over fields managed by humans or other controllers.

Use the workload identity, service resilience, observability, security testing, and Go systems skills for their canonical cross-cutting workflows.

Verification

Test at the smallest layer that proves the behavior:

  • unit tests for desired-state construction, diffs, classification, and provider translation;
  • API-server or envtest tests for schema, status, finalizers, watches, indexes, conflicts, and reconciliation;
  • provider contract tests for idempotency, lost responses, throttling, eventual consistency, and ownership checks;
  • upgrade tests for served and storage versions, conversion, changed defaults, rollback, and existing objects;
  • end-to-end tests for create, drift, partial failure, restart, deletion, retention, adoption, and orphan recovery.

Fake clients do not prove API-server behavior. envtest does not run every Kubernetes controller, so garbage collection and other control-plane behavior need explicit substitutes or real-cluster tests.

Run repository generation, formatting, lint, race, vulnerability, manifest, schema, and test commands. Confirm generated code and manifests are current and inspect their diff. See the testing and operations reference (${HANDBOOK_ROOT}/skills/kubernetes-operator-development/references/testing-operations.md).

Review Output

Lead with correctness and data-loss risks. Report:

  1. API and ownership contract.
  2. Reconciliation safety under retry, concurrency, and partial failure.
  3. Deletion, adoption, and upgrade hazards.
  4. Security, scale, and operability gaps.
  5. Exact verification evidence and remaining limitations.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Kubernetes Operator Development AI skill do?

Designs, implements, reviews, tests, and operates Kubernetes operators and controllers in Go with Kubebuilder and controller-runtime. Use when defining CRDs, reconciliation loops, status conditions, finalizers, admission webhooks, external-provider controllers, operator upgrades, envtest suites, or controller-runtime cache, retry, and concurrency behavior.

Why use Kubernetes Operator Development on TypingMind?

Because you install it once and use it with any model. Kubernetes Operator Development is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Kubernetes Operator Development in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/d-padmanabhan/agent-engineering-handbook/tree/main/skills/kubernetes-operator-development. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Kubernetes Operator Development?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Kubernetes Operator Development?

As many as you like. As long as a model supports skills, you can use Kubernetes Operator Development with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Kubernetes Operator Development AI skill free?

Yes. It is published on GitHub by d-padmanabhan under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇