---
name: "kubernetes-vpa-autoscaling"
description: "Automatically recommend and adjust CPU and memory requests/limits for Kubernetes pods."
metadata:
  author: "Kubernetes"
  version: "1.0.0"
  runtime_compatibility:
    - "codex"
    - "claude-code"
    - "cursor"
    - "windsurf"
triggers:
  - "setup k8s vpa"
  - "recommend cpu memory pod vpa"
  - "configure vertical pod autoscaler bounds"
permissions:
  fs_read: true
  fs_write: "workspace"
  shell_exec: false
  net_access: false
---

# Kubernetes VPA (Vertical Pod Autoscaler) Sizing

Implements VerticalPodAutoscaler (VPA): configuring recommendation mode (Off) vs automated actuation (Auto/Recreate), setting min/max allowed resource bounds, and eliminating OOM kills and over-provisioned cloud spend.

## When to Invoke
Invoke this skill whenever you need to:
- setup k8s vpa
- recommend cpu memory pod vpa
- configure vertical pod autoscaler bounds

## Execution SOP & Rules
1. Install VPA components: vpa-recommender, vpa-updater, and vpa-admission-controller.
2. Create VerticalPodAutoscaler resource pointing to target Deployment targetRef.
3. Set updateMode: 'Off' during initial observation phase (7-14 days) to capture true peak loads.
4. Inspect output: kubectl describe vpa <name> and compare target recommendations against current requests.

## Verification Checklist
- Run local linting, syntax validation, and type-checks before reporting completion.
- Ensure all created or modified files adhere to workspace boundaries and avoid uncommitted secrets.
- Verify tests or build commands exit cleanly with return code 0.
