skaffold
Files
SKILL.mdagentsreferences
Install
Install the containing plugin
/plugin install ci-cd@llm-skills
Invoke this skill after installation
/ci-cd:skaffold
This skill is bundled inside ci-cd. Install the plugin once, then Claude Code can use any of its included skills. Browse the full plugin repository at github.com/alisonaquinas/llm-ci-dev.
SKILL.md
name: skaffold description: Build, push, and deploy to Kubernetes iteratively with Skaffold. Use when tasks mention skaffold, skaffold dev, skaffold run, skaffold.yaml, or Skaffold build/deploy pipelines.
skaffold
Use this skill to keep Skaffold-based Kubernetes build and deploy workflows deterministic and safe across local and CI environments.
Intent Router
| Request | Reference | Load When |
|---|---|---|
| Install, prerequisites, registry config | references/install-and-setup.md | User needs to install Skaffold or configure image registry |
| dev/run/build/deploy/debug commands | references/command-cookbook.md | User needs to run Skaffold commands |
| skaffold.yaml structure, builders, deployers, sync | references/skaffold-yaml.md | User needs to configure skaffold.yaml |
| Profiles, CI integration, caching, multi-module | references/profiles-and-ci.md | User needs environment-specific configs or CI setup |
Quick Start
# Generate skaffold.yaml interactively
skaffold init
# Verify configuration before running
skaffold diagnose
# Start iterative dev loop (watches files, rebuilds on change)
skaffold dev
# One-shot build and deploy (for CI)
skaffold run --status-check
# Preview rendered manifests without deploying
skaffold render
Core Command Tracks
- Dev loop:
skaffold dev— watches source, rebuilds images, redeploys on change - CI deploy:
skaffold run— builds, pushes, and deploys once, then exits - Build only:
skaffold build— builds and pushes images without deploying - Deploy only:
skaffold deploy— deploys pre-built images from a build artifact - Delete:
skaffold delete— tears down resources deployed by Skaffold - Debug:
skaffold debug— dev loop with debugger port forwarding enabled - Render:
skaffold render— outputs hydrated manifests without applying them - Diagnose:
skaffold diagnose— validates skaffold.yaml and environment
Safety Guardrails
- Always use
skaffold diagnoseto verify configuration before running in CI. - Use
--default-repoorSKAFFOLD_DEFAULT_REPOto ensure images push to the correct registry. - Use
skaffold renderto preview manifests without deploying in production contexts. - In CI, use
skaffold runnotskaffold dev; dev mode watches files and blocks indefinitely. - Use profiles to separate dev, staging, and prod configurations rather than editing the base config.
- Enable
--status-checkin CI to catch failed deployments before marking a build as passing.
Workflow
- Run
skaffold initto generate an initialskaffold.yamlif one does not exist. - Run
skaffold diagnoseto validate the config and check prerequisites. - Set
SKAFFOLD_DEFAULT_REPOor--default-repoto point to the correct container registry. - Use
skaffold devfor local iterative development; useskaffold run --status-checkin CI. - Use profiles (
--profile) to switch between dev, staging, and prod configurations. - Run
skaffold renderto inspect manifests before committing to a deploy.
# Troubleshoot a failed CI deploy: check config validity then inspect rendered manifests
skaffold diagnose
skaffold render --profile ci
kubectl apply --dry-run=client -f -
Related Skills
- kubectl — direct Kubernetes resource management
- helm — Helm chart deployer used within Skaffold
- kustomize — Kustomize deployer used within Skaffold
- docker — container image building underlying Skaffold builders
- ci-architecture — CI pipeline patterns for Skaffold-based workflows
References
references/install-and-setup.mdreferences/command-cookbook.mdreferences/skaffold-yaml.mdreferences/profiles-and-ci.md- Official docs: https://skaffold.dev/docs/
- Command reference: https://skaffold.dev/docs/references/cli/