add-k8s-resource

Scaffolds Kubernetes CRD resources and operator wiring for the VMAFx project.

3|1|Updated May 28, 2026
One-click install
npx skills add https://github.com/VMAFx/vmafx --skill add-k8s-resource
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: add-k8s-resource
Source: https://github.com/VMAFx/vmafx/tree/main/.claude/skills/add-k8s-resource
Command: npx skills add https://github.com/VMAFx/vmafx --skill add-k8s-resource

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

It removes the repetitive boilerplate involved in adding a new Kubernetes custom resource to the VMAFx operator, so teams can ship new controller-backed APIs faster and with fewer mistakes.

Core Features & Use Cases

  • CRD Scaffolding: Generates the API types, controller stub, CRD manifest, RBAC rules, documentation page, and changelog fragment for a new resource.
  • Operator Wiring: Patches the operator manager, Helm values, and controller inventory so the new resource fits the existing deployment flow.
  • Guardrails and Conventions: Enforces naming rules, avoids overwriting files, keeps controllers disabled by default, and follows the project’s ADR-based conventions.
  • Use Case: When adding a new workload such as a benchmark run or model deployment resource, this Skill produces the full starter set needed to begin implementation safely.

Quick Start

Ask the skill to scaffold a new VMAFx Kubernetes resource named BenchmarkRun, and it will create the API types, controller stub, Helm manifest, RBAC rules, and documentation for you.

Frequently Asked Questions about add-k8s-resource

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I scaffold a new Kubernetes CRD and controller without writing boilerplate manually?

Scaffolding a Kubernetes CRD generates the API types, controller stub, CRD manifest, RBAC rules, and Helm chart entries automatically. This removes repetitive boilerplate so you can ship new custom resource APIs faster and with fewer mistakes.

What files are generated when adding a new custom resource to a kubebuilder-style operator?

Adding a custom resource generates API types, a controller stub, YAML manifests, RBAC rules, a documentation page, and a changelog fragment. It also patches the operator manager, Helm values, and controller inventory to wire the resource into existing deployment flows.

Do I need to validate my Kind name before scaffolding a Kubernetes CRD?

Yes, scaffolding requires validated PascalCase kind names before generating any files. Enforcing naming conventions ensures the generated API types, manifests, and controller stubs align with project conventions and avoid structural conflicts.

Can scaffolding a Kubernetes controller overwrite my existing API types or manifests?

No, the scaffolding process enforces guardrails that refuse to overwrite existing files. It keeps newly created controllers disabled by default to prevent accidental deployment or disruption of running operator workflows.

What is the best way to add a namespaced API and RBAC rules to a Kubernetes operator?

The best way is using a scaffolding tool that applies kubebuilder-style markers to generate the namespaced API, RBAC rules, and CRD manifest simultaneously. This ensures all components fit the existing deployment flow and follow ADR-based conventions.