[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7A7VKE7FQKFVEZWD9Z971CM":3,"skill-same:01M7A7VKE7FQKFVEZWD9Z971CM":133},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":48,"repositoryHtmlUrl":49,"repositoryHomepageUrl":6,"ownerHtmlUrl":50,"ownerBlogUrl":6,"ownerDescription":51,"updatedAt":52,"install":53,"resources":66},"01M7A7VKE7FQKFVEZWD9Z971CM","eks-cost-optimizer",null,"Optimizes EKS cluster costs via a layered analysis framework — right-sizes EC2 managed node groups from 14-30 day CloudWatch and Container Insights utilization, evaluates Fargate vs EC2 nodes (Fargate pay-per-pod at $0.04048\u002FvCPU-hr + $0.004445\u002FGB-hr; EC2 cheaper for steady-state dense scheduling), assesses Spot Instance node groups (up to 90% off, requires PodDisruptionBudget + graceful drain), compares Cluster Autoscaler vs Karpenter (consolidation, bin-packing, faster scale-up, 20-40% savings), finds bin-packing waste (requests vs limits gap, over-provisioned namespaces), and layers pricing-model optimization (Compute Savings Plans for the EC2 node baseline; control plane is fixed $73\u002Fmonth). Emits OPTIMIZED, OPPORTUNITY_FOUND with estimated monthly savings, or ALREADY_OPTIMAL. Use for EKS spend reviews, managed node group rightsizing, Karpenter evaluation, Fargate migration analysis, or FinOps Kubernetes plans.","jhkchan\u002Faws-agent-skills","jhkchan","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F1083902?v=4","01M7A2SVQYP9GQTPTDXP5JKYQ4","Jacky Chan","01M7A2SVS117YWCTZABB75HZR1",4,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: eks-cost-optimizer\ndescription: Optimizes EKS cluster costs via a layered analysis framework — right-sizes EC2 managed node groups from 14-30 day CloudWatch and Container Insights utilization, evaluates Fargate vs EC2 nodes (Fargate pay-per-pod at $0.04048\u002FvCPU-hr + $0.004445\u002FGB-hr; EC2 cheaper for steady-state dense scheduling), assesses Spot Instance node groups (up to 90% off, requires PodDisruptionBudget + graceful drain), compares Cluster Autoscaler vs Karpenter (consolidation, bin-packing, faster scale-up, 20-40% savings), finds bin-packing waste (requests vs limits gap, over-provisioned namespaces), and layers pricing-model optimization (Compute Savings Plans for the EC2 node baseline; control plane is fixed $73\u002Fmonth). Emits OPTIMIZED, OPPORTUNITY_FOUND with estimated monthly savings, or ALREADY_OPTIMAL. Use for EKS spend reviews, managed node group rightsizing, Karpenter evaluation, Fargate migration analysis, or FinOps Kubernetes plans.\nlicense: Apache-2.0\ncompatibility: Agent runtime that reads SKILL.md (Claude Code, Cursor, Windsurf, Codex, Gemini). Offline recommendation classification works from pasted Container Insights metrics and node group configurations. Live-account optimization uses aws eks describe-nodegroup, aws eks list-fargate-profiles, aws cloudwatch get-metric-statistics, aws ce get-cost-and-usage, aws ec2 describe-instance-types, and aws ce get-savings-plans-coverage (AWS CLI v2, SSO or key-based credentials). kubectl top nodes \u002F kubectl...\nmetadata:\n  domain: aws-cloudops\n  complexity: high\n  requires_llm: 'true'\n  phase: '3'\n  supports_pipeline: 'true'\n  entry_point: 'false'\n  family: Compute\n  task_type: optimize\n  skill_class: capability\n  lifecycle_status: active\n  verdict_shape: OPTIMIZED | OPPORTUNITY_FOUND | ALREADY_OPTIMAL\n  when_to_use: Right-sizing EKS managed node groups for cost, evaluating Fargate vs EC2 for a workload, planning a Spot node group migration, comparing Cluster Autoscaler vs Karpenter, identifying bin-packing waste (requests vs limits gap), planning a Compute Savings Plan for EKS nodes, or building a monthly savings estimate for an EKS FinOps initiative.\n  when_not_to_use: Auditing a single pod's resource requests (use VPA recommendations directly), troubleshooting a pod crash or OOMKill (use kubectl describe and application logs), EC2 instance rightsizing outside EKS (use ec2-rightsizing-optimizer), EKS security or RBAC audits (use the security audit skills), or EKS upgrade planning (use the deploy\u002Foperate skills). This skill focuses on cost-driven EKS optimization decisions.\n  activation_triggers: optimize EKS cluster cost, right-size EKS node group, Fargate vs EC2 nodes, EKS Spot Instance node group, Karpenter vs Cluster Autoscaler, Karpenter consolidation savings, EKS bin-packing optimization, Kubernetes requests vs limits, EKS Compute Savings Plan, EKS FinOps savings, reduce EKS node spend, EKS Graviton node group, EKS Auto Mode cost, EKS node group downsize, Kubernetes cost optimization\n  invocation_schema: 'Input: either (a) an EKS cluster identifier + live-account context, (b) a managed node group configuration with utilization data, OR (c) Container Insights metrics (node CPU, node memory, pod CPU, pod memory) for one or more node groups with at least 14 days of observation. Output: a deterministic TARGET\u002FVERDICT\u002FREASON\u002FRECOMMENDATION\u002FESTIMATED_SAVINGS\u002F MIGRATION_STEPS block per node group or cluster, where VERDICT is one of {OPTIMIZED, OPPORTUNITY_FOUND, ALREADY_OPTIMAL} and RECOMMENDATION includes the target node type, compute model (EC2\u002FFargate\u002FSpot), autoscaler strategy, and pricing model.'\n  invocation_example: \"# Minimal valid input (offline finding classification):\\nCluster: prod-cluster\\nRegion: us-east-1\\nNode group: prod-general-purpose\\nInstance type: m5.2xlarge\\nDesired size: 4 nodes (min 3, max 10)\\nCompute model: EC2 On-Demand managed node group\\nAutoscaler: Cluster Autoscaler\\nUtilization (Container Insights, last 30 days):\\n  - node_cpu_utilization: avg=12%, max=20%\\n  - node_memory_utilization: avg=25%, max=35%\\n  - Average pods per node: 8 (capacity ~30)\\nWorkload: mixed microservices (Java, Python, Go), multi-arch\\nDocker images available.\\nEmit the standard optimization block.\"\n  version: 0.1.0\n  author: Jacky Chan — AWS Community Builder\n  keywords: EKS, Kubernetes, cost optimization, managed node group, Fargate, Spot Instances, Karpenter, Cluster Autoscaler, bin-packing, PodDisruptionBudget, requests, limits, Container Insights, Compute Savings Plans, FinOps, node group right-sizing, EKS Auto Mode, consolidation, Graviton, Vertical Pod Autoscaler\n  tags: eks, kubernetes, compute, cost-optimization, finops, fargate, karpenter, spot\n---\n\n# EKS Cost Optimizer\n\n## Quick start\n\n- **Node utilization is the starting signal, not the final answer.** Low\n  node CPU\u002Fmemory tells you the node group is overprovisioned, but the root\n  cause is usually the gap between pod `requests` and actual usage. Fix the\n  requests first (Step 6 — bin-packing), then right-size the node group.\n- **Decision framework (apply in order):**\n  - Bin-packing waste (requests >> usage) → reduce requests first (Step 6).\n  - Node group right-sizing (CPU \u003C 30% + Memory \u003C 50% after request fix) →\n    downsize instance type or reduce desired count (Step 5).\n  - Fargate vs EC2 (Step 4): Fargate for sporadic\u002Fdev\u002Flow-density; EC2 for\n    steady-state high-density.\n  - Spot node groups (Step 7): up to 90% off for fault-tolerant workloads.\n  - Karpenter vs Cluster Autoscaler (Step 8): Karpenter saves 20-40%.\n  - Pricing model (Step 9): Compute Savings Plan for the EC2 baseline.\n- **Fargate is pay-per-pod, not pay-per-node.** 10 pods at 1 vCPU + 2 GB\n  each on Fargate cost ~$360\u002Fmonth; the same 10 pods on one m5.large cost\n  ~$70\u002Fmonth. Fargate wins at low density; EC2 wins for steady-state.\n- **The EKS control plane is a fixed cost ($0.10\u002Fhour = $73\u002Fmonth).**\n  Right-sizing nodes does not reduce the control plane bill. Cluster\n  consolidation is the only lever for control plane savings.\n\n## STRICT output contract\n\nEvery optimization response MUST emit this block per target (node group or\ncluster). No prose before or after the block; the block is the entire\nactionable output.\n\n```text\nTARGET: \u003Ccluster-name\u002Fnode-group-name>\nVERDICT: OPTIMIZED | OPPORTUNITY_FOUND | ALREADY_OPTIMAL\nREASON: \u003C1-2 sentences naming the recommendation and the supporting data>\nRECOMMENDATION:\n  Current: \u003Cinstance-type x N nodes | Fargate profile> at \u003Cpricing-model>\n  Proposed: \u003Cinstance-type x N nodes | Fargate profile | Spot> at \u003Cpricing-model>\n  Compute model: \u003CEC2 On-Demand | EC2 Spot | Fargate | mixed>\n  Autoscaler: \u003CCluster Autoscaler | Karpenter | EKS Auto Mode>\n  Bin-packing action: \u003Creduce requests | VPA recommendation | none>\n  Graviton: \u003Cyes\u002Fno\u002FN\u002FA>\n  Confidence: \u003CHIGH\u002FMEDIUM\u002FLOW> — \u003Cone-line rationale>\nESTIMATED_SAVINGS:\n  Monthly (right-size + bin-pack): $\u003Camount>\n  Monthly (compute model): $\u003Camount>\n  Monthly (pricing model): $\u003Camount>\n  Annual total: $\u003Camount>\n  Assumptions: \u003C730h\u002Fmonth, pricing region, etc.>\nMIGRATION_STEPS:\n  1. \u003Cspecific action with CLI or kubectl command>\n  2. \u003Cverification step>\nCONFIRM: Before executing any state-changing CLI, emit and await operator\n  approval: \"CONFIRM: About to \u003Caction> on \u003Cnode-group> in \u003Ccluster>.\n  Proceed? (yes\u002Fno)\"\n```\n\nDo NOT omit any field. If a field is not applicable, write `N\u002FA` with a\none-line reason. A missing ESTIMATED_SAVINGS block is a contract violation.\n\n## Quick navigation\n\n| Section | What it covers | When to read it |\n|---|---|---|\n| **§ Quick start** | Decision framework order, Fargate vs EC2 rule of thumb | First read |\n| **§ STRICT output contract** | Mandatory output block format | Before emitting any response |\n| **§ Mindset** | Bin-packing precedes node right-sizing, Fargate breakeven, Spot safety | Understanding the philosophy |\n| **§ Quick reference** | Verdict thresholds (OPPORTUNITY_FOUND\u002FOPTIMIZED\u002FALREADY_OPTIMAL) | Classifying findings |\n| **§ Pre-flight** | Data gate — Container Insights, kubectl top requirements | Before any right-sizing decision |\n| **§ Process** | Ordered optimization steps (1-10): bin-packing, node sizing, Fargate, Spot, Karpenter, pricing | Choosing recommendations |\n| **§ Output format** | Worked example (OPPORTUNITY_FOUND) | Formatting the response |\n| **§ Expert heuristic** | Consolidated non-obvious EKS cost behaviours table | Review before complex decisions |\n| **§ NEVER** | Top 5 anti-patterns that cause pod eviction, data loss, or false savings | Review before remediation |\n| `references\u002F` | CLI commands, extra worked examples, full NEVER list, detailed heuristics | Deep reference |\n\n## Mindset\n\nEKS cost optimization is a layered decision. Four behaviours separate a\nsenior Kubernetes FinOps engineer from a generalist:\n\n- **Bin-packing precedes node right-sizing.** If pods request 4 vCPU but\n  use 0.5 vCPU, nodes appear fully scheduled while actually 90% idle.\n  Right-sizing nodes first produces pending pods. Always fix requests\n  (Step 6) before changing instance types. #1 cause of failed EKS\n  right-sizing.\n- **Fargate has a breakeven density, not a universal advantage.** Below\n  ~3-4 steady pods per equivalent EC2 node, Fargate is cheaper. Above that,\n  EC2 amortizes cost across more pods. Always compute the breakeven.\n- **Spot savings require a safety contract.** A Spot node group without\n  PDB + graceful drain (NTH\u002FKarpenter) causes data loss and 502s. The\n  safety contract is non-negotiable.\n- **Karpenter consolidation is the highest-leverage switch.** Moving from\n  Cluster Autoscaler to Karpenter typically saves 20-40% through better\n  bin-packing and consolidation of underutilized nodes.\n\n## Quick reference — verdict thresholds\n\n| Observation (14-30 day window) | Verdict | Recommendation |\n|---|---|---|\n| Node CPU \u003C 30% avg AND node Memory \u003C 50% avg AND requests ~= usage | **OPPORTUNITY_FOUND** (downsize node group) | Step 5 — reduce instance size or desired count |\n| Pod requests >> actual usage (requests\u002Fusage ratio > 2x) | **OPPORTUNITY_FOUND** (bin-packing) | Step 6 — reduce requests via VPA or manual tuning, then re-evaluate nodes |\n| Sporadic\u002Fdev workload on steady EC2 nodes with low pod density (\u003C 3 pods\u002Fnode) | **OPPORTUNITY_FOUND** (Fargate migration) | Step 4 — migrate to Fargate profile |\n| Steady-state, > 8 pods\u002Fnode, fault-tolerant, no PDB gap | **OPPORTUNITY_FOUND** (Spot node group) | Step 7 — Spot node group or Karpenter Spot capacity |\n| Cluster Autoscaler with empty\u002Funderutilized nodes | **OPPORTUNITY_FOUND** (Karpenter) | Step 8 — migrate to Karpenter for consolidation |\n| EC2 nodes at On-Demand pricing for steady-state baseline | **OPPORTUNITY_FOUND** (pricing model) | Step 9 — Compute Savings Plan |\n| Container Insights metrics absent (no observability) | **NEED_MORE_INFO** | Enable Container Insights, wait 14 days, re-evaluate |\n| All dimensions optimized: Karpenter + Spot + Savings Plan + tight requests | **ALREADY_OPTIMAL** | None — continue monitoring |\n| Post-remediation: changes applied and metrics confirm healthy utilization | **OPTIMIZED** | None — verification passed |\n\n## Pre-flight: data gate (run before any right-sizing decision)\n\n**Required data:** Container Insights node CPU\u002Fmemory utilization (14-30\nday window), pod-level usage for bin-packing analysis, node group\nconfiguration, and (optionally) `kubectl top nodes` for real-time signals.\nKey commands: `aws cloudwatch get-metric-statistics` for Container Insights\nmetrics, `kubectl top nodes` for live utilization, `kubectl describe node`\nfor allocatable resources.\n\nFull CLI sequences for data gathering are in\n`references\u002Feks-cost-reference.md` → \"Pre-flight data-gathering CLI commands\".\n\n### Data-quality short-circuits\n\n| Condition | Effect on optimization |\n|---|---|\n| Container Insights not enabled | **NEED_MORE_INFO**: Enable, wait 14 days. Do NOT recommend downsize without data. |\n| Observation window \u003C 14 days | **NEED_MORE_INFO**: may reflect atypical load. |\n| kubectl access unavailable (offline plan) | Rely on Container Insights. Mark bin-packing analysis MEDIUM confidence. |\n| Node group `DesiredSize: 0` (scaled to zero) | Skip — no cost to optimize. |\n| Fargate profile present but 0 running Fargate pods | Fargate charges per pod, not per profile. Skip. |\n\n### Conflicting-data arbitration\n\nWhen Container Insights and `kubectl top nodes` disagree, trust `kubectl\ntop nodes` (fresher, from the kubelet). When Container Insights and\nCloudWatch `AWS\u002FEC2` CPUUtilization disagree, trust Container Insights\n(`node_cpu_utilization` accounts for kubelet overhead).\n\n## Process — Optimization logic (apply in order)\n\n### Step 1: Validate input and data sufficiency\n\nIf Container Insights metrics (`node_cpu_utilization`,\n`node_memory_utilization`) are absent, emit NEED_MORE_INFO:\n\n```text\nTARGET: \u003Ccluster\u002Fnode-group>\nVERDICT: NEED_MORE_INFO\nREASON: Container Insights metrics are absent for this node group.\n  Without node CPU + memory utilization data, a node downsize\n  recommendation is a guess.\nRECOMMENDATION:\n  1. Enable Container Insights:\n     aws eks update-cluster-config --name \u003Ccluster> \\\n       --logging '{\"clusterLogging\":[{\"types\":[\"api\",\"audit\",\"authenticator\",\"controllerManager\",\"scheduler\"],\"enabled\":true}]}'\n  2. Verify metrics appear:\n     aws cloudwatch list-metrics --namespace ContainerInsights \\\n       --metric-name node_cpu_utilization \\\n       --dimensions Name=ClusterName,Value=\u003Ccluster>\n  3. Wait 14-30 days for representative data.\n  4. Re-evaluate.\nESTIMATED_SAVINGS: $0 (cannot quantify without utilization data)\n```\n\nIf the observation window \u003C 14 days, emit NEED_MORE_INFO. Proceed only if\ndata sufficiency passes.\n\n### Step 2: Node group inventory and current cost\n\nGather the node group configuration:\n\n```bash\naws eks describe-nodegroup --cluster-name \u003Ccluster> --nodegroup-name \u003Cng> \\\n  --output json | jq '{\n    instance_types: .nodegroup.instanceTypes,\n    desired: .nodegroup.scalingConfig.desiredSize,\n    min: .nodegroup.scalingConfig.minSize,\n    max: .nodegroup.scalingConfig.maxSize,\n    capacity_type: .nodegroup.capacityType,\n    ami_type: .nodegroup.amiType\n  }'\n```\n\nCompute current monthly node cost: `monthly = instance_hourly *\ndesired_size * 730`. Add the control plane cost ($73\u002Fmonth) pro-rated if\nanalyzing per-cluster.\n\n### Step 3: Bin-packing analysis (apply early)\n\nCheck whether pod `requests` are inflated relative to actual usage before\nright-sizing nodes:\n\n```bash\nkubectl get pods --all-namespaces -o json | jq '.items[] | {\n  pod: .metadata.name, cpu_request: .spec.containers[].resources.requests.cpu,\n  mem_request: .spec.containers[].resources.requests.memory}'\nkubectl top pods --all-namespaces\n```\n\n| Requests\u002Fusage ratio | Bin-packing verdict | Action |\n|---|---|---|\n| ratio \u003C 1.5x | Healthy | Proceed to node right-sizing (Step 5) |\n| ratio 1.5-3x | Moderate waste | Step 6 — reduce requests to p95 usage |\n| ratio > 3x | Severe waste | Step 6 — reduce requests FIRST, then re-evaluate nodes |\n\nIf ratio > 2x, node right-sizing is blocked on bin-packing — fix requests\nfirst. CLI commands in `references\u002Feks-cost-reference.md`.\n\n### Step 4: Fargate vs EC2 evaluation\n\n**Fargate recommended when:** pod density \u003C 3-4 per EC2 node, sporadic\nworkload, no DaemonSets\u002Fprivileged pods, zero node management desired.\n\n**EC2 recommended when:** steady-state with > 6 pods\u002Fnode, DaemonSets in\nuse, specific instance features needed (GPU, NVMe), Spot savings priority.\n\n**Fargate breakeven:**\n```\nfargate_pod_hourly = (vCPU_request * $0.04048) + (GB_request * $0.004445)\nec2_cost_per_pod = ec2_node_hourly \u002F ec2_pods_per_node\n# Fargate cheaper when fargate_pod_hourly \u003C ec2_cost_per_pod\n```\nFargate Spot offers up to 75% off for interruptible workloads.\n\n### Step 5: Node group right-sizing (after bin-packing is fixed)\n\n| Node utilization (30-day avg) | Action |\n|---|---|\n| CPU \u003C 30% AND Memory \u003C 50% | Downsize: reduce instance type by 1-2 sizes OR reduce desired count by 25-50%. |\n| CPU > 70% OR Memory > 80% | Upsize: increase instance type or desired count. |\n| 30-70% CPU, 50-80% Memory | Correctly sized. Proceed to Spot\u002Fpricing evaluation. |\n\n**Downsize:** Option A — create new node group with smaller type, drain\nold group, shift traffic (safer for production). Option B — update existing\ngroup's instance type (faster, rolling rescheduling).\n\n**Graviton:** requires multi-arch (arm64) container images. Types: m7g,\nc7g, r7g (up to 40% better price-performance).\n\n### Step 6: Bin-packing optimization (requests adjustment)\n\nReduce pod `requests` to match actual p95\u002Fp99 usage.\n\n| Resource | Recommendation rule |\n|---|---|\n| CPU request | p95 CPU usage over 30 days. Round up to nearest 25m. |\n| Memory request | p99 memory usage + 10-15% buffer (OOMKill risk). |\n| CPU limit | 2x request for burst workloads, or remove for latency-sensitive. |\n| Memory limit | >= request. A limit below request causes OOMKill. |\n\nAfter adjusting requests, re-evaluate node utilization (Step 5).\n\n### Step 7: Spot node group evaluation\n\n**Spot readiness checklist (ALL must pass):**\n1. Workload is stateless or tolerates graceful shutdown (2-min warning).\n2. PodDisruptionBudget configured for all deployments:\n   `kubectl get pdb --all-namespaces` — confirm `minAvailable` or\n   `maxUnavailable` set on every deployment.\n3. Graceful drain mechanism (NTH for Cluster Autoscaler; Karpenter native\n   disruption handling).\n4. Multi-AZ scheduling (topology spread constraints or anti-affinity) to\n   avoid correlated Spot interruptions.\n5. No stateful workloads (databases, queues) on Spot nodes — use\n   persistent EC2 On-Demand for stateful workloads.\n6. `terminationGracePeriodSeconds` set appropriately (default 30s; increase\n   for workloads needing graceful shutdown).\n\n**Recommendation:** Cluster Autoscaler → separate Spot node group + On-Demand\ngroup with selectors\u002Ftolerations. Karpenter → NodePool with Spot capacity\nand 3+ instance type alternatives.\n\n### Step 8: Cluster Autoscaler vs Karpenter evaluation\n\n| Dimension | Cluster Autoscaler | Karpenter |\n|---|---|---|\n| Scaling trigger | Pending pods | Pending pods + consolidation |\n| Consolidation | Only removes empty nodes | Removes empty + replaces underutilized nodes |\n| Spot handling | Requires NTH | Native disruption handling |\n| Instance flexibility | Constrained by node group config | Selects from instance type list automatically |\n| Typical savings | — | 20-40% over Cluster Autoscaler |\n\n**Recommendation:** If running Cluster Autoscaler with underutilized nodes\n(\u003C 40% CPU), migrating to Karpenter with consolidation enabled is typically\nthe highest-leverage single change.\n\n**Karpenter migration steps:**\n1. Install Karpenter via Helm.\n2. Create a NodePool with instance type alternatives and consolidation\n   enabled (`disruption.consolidationPolicy: WhenEmptyOrUnderutilized`).\n3. Cordon the Cluster Autoscaler-managed node group gradually.\n4. Karpenter provisions replacement nodes and consolidates.\n5. Remove Cluster Autoscaler once all workloads are on Karpenter nodes.\n\n### Step 9: Pricing model optimization\n\n| Node group pattern | Recommended model | Savings vs On-Demand |\n|---|---|---|\n| Steady-state On-Demand baseline | 3-year Compute Savings Plan | 50-72% |\n| Variable nodes (auto-scaling) | 1-yr CSP for baseline + On-Demand for spikes | 30-40% |\n| Spot-eligible burst nodes | Spot Instances | Up to 90% |\n| Fargate pods | No Savings Plan (not covered) | 0% (Fargate Spot: up to 75%) |\n\n**Commitment laddering:** commit a 1-3 year CSP for the steady-state EC2\nbaseline, use Spot for fault-tolerant burst, On-Demand for unpredictable spikes.\n\n### Step 10: Impact estimation and final verdict\n\n```\nBin-packing savings = freed_node_count * node_hourly * 730\nFargate migration savings = (ec2_cost - fargate_pod_cost) * 730\nSpot savings = (on_demand_hourly - spot_hourly) * node_count * 730\nKarpenter savings = (pre_nodes - post_nodes) * node_hourly * 730\nSavings Plan savings = committed_spend * discount_rate\n```\n\nVerdict: any dimension with a concrete recommendation → **OPPORTUNITY_FOUND**.\nAll dimensions pass + pricing optimized → **OPTIMIZED** or **ALREADY_OPTIMAL**.\nData insufficient → **NEED_MORE_INFO**.\n\n## Output format\n\nSee § STRICT output contract for the mandatory block. Worked example below.\nAdditional examples (Fargate migration, already optimal, NEED_MORE_INFO) in\n`references\u002Feks-cost-reference.md`.\n\n### Worked example — overprovisioned node group + bin-packing + Karpenter\n\n```text\nTARGET: prod-cluster\u002Fprod-general-purpose\nVERDICT: OPPORTUNITY_FOUND\nREASON: m5.2xlarge node group (4 nodes) at 12% CPU \u002F 25% Memory over 30 days\n  is overprovisioned. Root cause: pod requests inflated 4x vs actual usage.\n  Fix requests (Step 6), downsize to m7i.xlarge (Step 5), migrate to\n  Karpenter for consolidation (Step 8), and commit a 3-year Compute Savings\n  Plan on the reduced baseline (Step 9).\nRECOMMENDATION:\n  Current: m5.2xlarge x 4 nodes at On-Demand via Cluster Autoscaler\n  Proposed: m7i.xlarge x 2 nodes at 3-year Compute Savings Plan via Karpenter\n  Compute model: EC2 On-Demand → EC2 On-Demand (Karpenter-managed)\n  Autoscaler: Cluster Autoscaler → Karpenter (consolidation enabled)\n  Bin-packing action: reduce CPU requests from 4000m to 1000m per pod via VPA\n  Graviton: N\u002FA (some pods lack arm64 images; revisit after multi-arch build)\n  Confidence: HIGH — Container Insights reporting, kubectl top confirms low\n    usage, requests\u002Fusage ratio 4.2x (severe waste).\nESTIMATED_SAVINGS:\n  Monthly (right-size + bin-pack): $896.64  (m5.2xlarge $0.384\u002Fh x 4 →\n    m7i.xlarge $0.192\u002Fh x 2; 730h x $1.152 delta)\n  Monthly (Karpenter consolidation): $280.32  (estimated 30% further\n    node reduction from consolidation vs Cluster Autoscaler)\n  Monthly (pricing model): $112.22  (50% off m7i.xlarge On-Demand via\n    3-yr Compute Savings Plan on 2 nodes)\n  Annual total: $15,447.36\n  Assumptions: 730h\u002Fmonth, us-east-1 pricing, Karpenter consolidation\n    estimate is conservative (20-40% range).\nMIGRATION_STEPS:\n  1. Deploy VPA in recommend mode and review recommendations for top-20\n     pods by request\u002Fusage gap:\n     kubectl get vpa -n prod --output json | jq '.items[].status.recommendation'\n  2. Apply reduced CPU requests (4000m → 1000m) to deployments:\n     kubectl patch deployment \u003Cname> -n prod --type json \\\n       -p '[{\"op\":\"replace\",\"path\":\"\u002Fspec\u002Ftemplate\u002Fspec\u002Fcontainers\u002F0\u002Fresources\u002Frequests\u002Fcpu\",\"value\":\"1000m\"}]'\n  3. Install Karpenter and create a NodePool with m7i.xlarge as the\n     primary instance type and consolidation enabled:\n     helm install karpenter oci:\u002F\u002Fpublic.ecr.aws\u002Fkarpenter\u002Fkarpenter \\\n       -n karpenter --create-namespace\n     kubectl apply -f karpenter-nodepool.yaml\n  4. Cordon the old Cluster Autoscaler node group gradually (one node at\n     a time) and verify pods reschedule onto Karpenter nodes:\n     kubectl cordon \u003Cnode> && kubectl drain \u003Cnode> --ignore-daemonsets\n  5. Once all pods are on Karpenter nodes, delete the old node group:\n     aws eks delete-nodegroup --cluster-name prod-cluster \\\n       --nodegroup-name prod-general-purpose\n  6. Purchase a 3-year Compute Savings Plan for the m7i.xlarge baseline:\n     aws savingsplans create-savings-plan --savings-plan-offering-id \u003Cid> \\\n       --commitment \"\u003Chourly-amount>\"\nCONFIRM: Before installing Karpenter and cordoning nodes, emit and await:\n  \"CONFIRM: About to install Karpenter on prod-cluster and cordon the\n   prod-general-purpose node group. Pods will reschedule with brief\n   scheduling delays. Proceed? (yes\u002Fno)\"\n  Do NOT execute until the operator confirms.\n```\n\n## Verdict semantics\n\n| Verdict | When to emit |\n|---|---|\n| `OPPORTUNITY_FOUND` | At least one dimension has a concrete, savings-bearing recommendation. |\n| `OPTIMIZED` | Changes applied and verified this session; metrics confirm healthy bands. |\n| `ALREADY_OPTIMAL` | All dimensions optimized (Karpenter + Spot + Savings Plan + tight requests). |\n| `NEED_MORE_INFO` | Container Insights absent or observation window \u003C 14 days. Emit before any sizing recommendation. |\n| `BLOCKED` | Spot readiness check failed and the ONLY recommendation was Spot. |\n\n**Rule:** never emit `OPPORTUNITY_FOUND` without first discharging every\n`NEED_MORE_INFO` gate in Step 1.\n\n## Expert heuristic — consolidated\n\n| Heuristic | Impact on recommendation |\n|---|---|\n| Requests is the scheduling currency, not limits or usage | Check requests\u002Fusage ratio before node right-sizing. Inflated requests mask real utilization. |\n| Fargate does not support DaemonSets or privileged pods | Verify no DaemonSet dependencies before recommending Fargate. #1 migration blocker. |\n| Fargate charges per pod-request, not per pod-usage | Right-sizing the pod's own requests is the only Fargate lever. |\n| Spot gives 2-min warning; NTH\u002FKarpenter needed for graceful drain | Never recommend Spot without verifying PDB + drain mechanism. |\n| Karpenter consolidation deletes empty nodes AND replaces underutilized ones | Cluster Autoscaler only removes empty nodes. Replace mode is the 20-40% savings source. |\n| Graviton nodes need multi-arch container images | Verify arm64 manifest before recommending. Single-arch x86 fails on arm64. |\n| Compute Savings Plans cover EC2 nodes, NOT Fargate | Never claim Savings Plan savings on Fargate spend. |\n| Managed node group updates respect PDB | A PDB that blocks drainage stalls node group updates. |\n| Cross-AZ pod-to-pod traffic within a cluster is free | Right-sizing that changes AZ distribution does not add intra-cluster transfer cost. |\n| EKS control plane is $0.10\u002Fhour ($73\u002Fmonth) fixed | Node right-sizing does not reduce control plane cost. |\n| EKS Auto Mode bundles Karpenter-like provisioning | For new clusters, Auto Mode eliminates separate Karpenter installation. |\n| cluster-autoscaler never consolidates partially-used nodes | If nodes are 30% utilized but not empty, recommend Karpenter. |\n\n## NEVER (top 5 — full list in references)\n\n- NEVER recommend a node group downsize without first checking the pod\n  requests-to-usage ratio. Inflated requests produce pending pods.\n- NEVER recommend Fargate without verifying no DaemonSets, privileged pods,\n  or hostNetwork are in use. #1 Fargate migration failure.\n- NEVER recommend Spot without verifying PDB and graceful drain (NTH or\n  Karpenter). Without these, Spot interruptions cause data loss.\n- NEVER claim Compute Savings Plan savings on Fargate spend. CSPs apply to\n  EC2 instance spend only.\n- NEVER recommend a single instance type for a Spot node group or Karpenter\n  NodePool. Always provide 3+ alternative instance types.\n\n## Pre-flight safety checks (run before any remediation CLI)\n\n- **MANDATORY CONFIRMATION GATE** before any state-changing operation.\n- **Verify PDB before Spot migration:** `kubectl get pdb --all-namespaces`.\n- **Verify multi-arch images before Graviton:** `docker manifest inspect \u003Cimage>`.\n- **Verify no DaemonSet dependencies before Fargate:** `kubectl get ds --all-namespaces`.\n- **Drain nodes one at a time** during cutover.\n- **Batch limit:** max 3 node groups per batch, single CONFIRM, verify before next.\n- **Capture pre-state:** snapshot `describe-nodegroup` output before changes.\n\nFull detail in `references\u002Feks-cost-reference.md` → \"Pre-flight safety checks\".\n\n## Recent AWS features (2024-2026)\n\n- **EKS Auto Mode (2024-2025):** Managed compute auto-provisioning that\n  bundles Karpenter-like node management. Auto Mode handles instance\n  selection, Spot\u002FOn-Demand mix, and consolidation automatically. For new\n  clusters, Auto Mode eliminates the need to install Karpenter separately.\n\n- **Karpenter consolidation improvements (v0.32+, 2024-2025):** Disruption\n  budgets (`disruption.budgets`) allow rate-limiting consolidation to\n  control node churn in production. `WhenEmptyOrUnderutilized` is the\n  recommended consolidation policy for steady-state clusters.\n\n- **Graviton 4 (2024-2025):** Broad rollout across EKS-supported instance\n  types. Graviton 4 nodes offer up to 30% better performance than Graviton 3.\n\n- **Fargate pricing unchanged:** $0.04048\u002FvCPU-hour + $0.004445\u002FGB-hour\n  (us-east-1). Fargate Spot remains up to 75% off. Still not covered by\n  Compute Savings Plans (as of 2026).\n\n- **Compute Savings Plans enhancements (2024):** More flexible commitment\n  terms. Use for any EKS EC2 node baseline with uncertain workload growth.\n\n- **EKS Container Insights enhanced observability (2024-2025):** Per-pod\n  cost allocation via KubeCost integration. Recommended for FinOps-grade\n  cluster analysis.\n\n- **Spot Placement Score for EKS (2024-2025):** Predicts Spot capacity\n  availability before provisioning Spot node groups.\n\n## Domain\n\nAWS CloudOps \u002F EKS Kubernetes Compute Cost Optimization & FinOps.\n\n## AWS documentation\n\n- **Amazon EKS User Guide** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fwhat-is-eks.html\n- **EKS Pricing** — https:\u002F\u002Faws.amazon.com\u002Feks\u002Fpricing\u002F\n- **AWS Fargate Pricing** — https:\u002F\u002Faws.amazon.com\u002Ffargate\u002Fpricing\u002F\n- **EKS Managed Node Groups** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fmanaged-node-groups.html\n- **Karpenter** — https:\u002F\u002Fkarpenter.sh\u002F\n- **Container Insights** — https:\u002F\u002Fdocs.aws.amazon.com\u002FAmazonCloudWatch\u002Flatest\u002Fmonitoring\u002FContainer-Insights-metrics-EKS.html\n- **EKS Auto Mode** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fauto-mode.html\n- **Spot Instances for EKS** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fspot.html\n- **PodDisruptionBudgets** — https:\u002F\u002Fkubernetes.io\u002Fdocs\u002Ftasks\u002Frun-application\u002Fconfigure-pdb\u002F\n- **AWS CLI EKS reference** — https:\u002F\u002Fdocs.aws.amazon.com\u002Fcli\u002Flatest\u002Freference\u002Feks\u002F\n- **AWS Well-Architected Framework — Cost Optimization** — https:\u002F\u002Fdocs.aws.amazon.com\u002Fwellarchitected\u002Flatest\u002Fcost-optimization-pillar\u002Fwelcome.html\n","# EKS Cost Optimizer\n\n## Quick start\n\n- **Node utilization is the starting signal, not the final answer.** Low\n  node CPU\u002Fmemory tells you the node group is overprovisioned, but the root\n  cause is usually the gap between pod `requests` and actual usage. Fix the\n  requests first (Step 6 — bin-packing), then right-size the node group.\n- **Decision framework (apply in order):**\n  - Bin-packing waste (requests >> usage) → reduce requests first (Step 6).\n  - Node group right-sizing (CPU \u003C 30% + Memory \u003C 50% after request fix) →\n    downsize instance type or reduce desired count (Step 5).\n  - Fargate vs EC2 (Step 4): Fargate for sporadic\u002Fdev\u002Flow-density; EC2 for\n    steady-state high-density.\n  - Spot node groups (Step 7): up to 90% off for fault-tolerant workloads.\n  - Karpenter vs Cluster Autoscaler (Step 8): Karpenter saves 20-40%.\n  - Pricing model (Step 9): Compute Savings Plan for the EC2 baseline.\n- **Fargate is pay-per-pod, not pay-per-node.** 10 pods at 1 vCPU + 2 GB\n  each on Fargate cost ~$360\u002Fmonth; the same 10 pods on one m5.large cost\n  ~$70\u002Fmonth. Fargate wins at low density; EC2 wins for steady-state.\n- **The EKS control plane is a fixed cost ($0.10\u002Fhour = $73\u002Fmonth).**\n  Right-sizing nodes does not reduce the control plane bill. Cluster\n  consolidation is the only lever for control plane savings.\n\n## STRICT output contract\n\nEvery optimization response MUST emit this block per target (node group or\ncluster). No prose before or after the block; the block is the entire\nactionable output.\n\n```text\nTARGET: \u003Ccluster-name\u002Fnode-group-name>\nVERDICT: OPTIMIZED | OPPORTUNITY_FOUND | ALREADY_OPTIMAL\nREASON: \u003C1-2 sentences naming the recommendation and the supporting data>\nRECOMMENDATION:\n  Current: \u003Cinstance-type x N nodes | Fargate profile> at \u003Cpricing-model>\n  Proposed: \u003Cinstance-type x N nodes | Fargate profile | Spot> at \u003Cpricing-model>\n  Compute model: \u003CEC2 On-Demand | EC2 Spot | Fargate | mixed>\n  Autoscaler: \u003CCluster Autoscaler | Karpenter | EKS Auto Mode>\n  Bin-packing action: \u003Creduce requests | VPA recommendation | none>\n  Graviton: \u003Cyes\u002Fno\u002FN\u002FA>\n  Confidence: \u003CHIGH\u002FMEDIUM\u002FLOW> — \u003Cone-line rationale>\nESTIMATED_SAVINGS:\n  Monthly (right-size + bin-pack): $\u003Camount>\n  Monthly (compute model): $\u003Camount>\n  Monthly (pricing model): $\u003Camount>\n  Annual total: $\u003Camount>\n  Assumptions: \u003C730h\u002Fmonth, pricing region, etc.>\nMIGRATION_STEPS:\n  1. \u003Cspecific action with CLI or kubectl command>\n  2. \u003Cverification step>\nCONFIRM: Before executing any state-changing CLI, emit and await operator\n  approval: \"CONFIRM: About to \u003Caction> on \u003Cnode-group> in \u003Ccluster>.\n  Proceed? (yes\u002Fno)\"\n```\n\nDo NOT omit any field. If a field is not applicable, write `N\u002FA` with a\none-line reason. A missing ESTIMATED_SAVINGS block is a contract violation.\n\n## Quick navigation\n\n| Section | What it covers | When to read it |\n|---|---|---|\n| **§ Quick start** | Decision framework order, Fargate vs EC2 rule of thumb | First read |\n| **§ STRICT output contract** | Mandatory output block format | Before emitting any response |\n| **§ Mindset** | Bin-packing precedes node right-sizing, Fargate breakeven, Spot safety | Understanding the philosophy |\n| **§ Quick reference** | Verdict thresholds (OPPORTUNITY_FOUND\u002FOPTIMIZED\u002FALREADY_OPTIMAL) | Classifying findings |\n| **§ Pre-flight** | Data gate — Container Insights, kubectl top requirements | Before any right-sizing decision |\n| **§ Process** | Ordered optimization steps (1-10): bin-packing, node sizing, Fargate, Spot, Karpenter, pricing | Choosing recommendations |\n| **§ Output format** | Worked example (OPPORTUNITY_FOUND) | Formatting the response |\n| **§ Expert heuristic** | Consolidated non-obvious EKS cost behaviours table | Review before complex decisions |\n| **§ NEVER** | Top 5 anti-patterns that cause pod eviction, data loss, or false savings | Review before remediation |\n| `references\u002F` | CLI commands, extra worked examples, full NEVER list, detailed heuristics | Deep reference |\n\n## Mindset\n\nEKS cost optimization is a layered decision. Four behaviours separate a\nsenior Kubernetes FinOps engineer from a generalist:\n\n- **Bin-packing precedes node right-sizing.** If pods request 4 vCPU but\n  use 0.5 vCPU, nodes appear fully scheduled while actually 90% idle.\n  Right-sizing nodes first produces pending pods. Always fix requests\n  (Step 6) before changing instance types. #1 cause of failed EKS\n  right-sizing.\n- **Fargate has a breakeven density, not a universal advantage.** Below\n  ~3-4 steady pods per equivalent EC2 node, Fargate is cheaper. Above that,\n  EC2 amortizes cost across more pods. Always compute the breakeven.\n- **Spot savings require a safety contract.** A Spot node group without\n  PDB + graceful drain (NTH\u002FKarpenter) causes data loss and 502s. The\n  safety contract is non-negotiable.\n- **Karpenter consolidation is the highest-leverage switch.** Moving from\n  Cluster Autoscaler to Karpenter typically saves 20-40% through better\n  bin-packing and consolidation of underutilized nodes.\n\n## Quick reference — verdict thresholds\n\n| Observation (14-30 day window) | Verdict | Recommendation |\n|---|---|---|\n| Node CPU \u003C 30% avg AND node Memory \u003C 50% avg AND requests ~= usage | **OPPORTUNITY_FOUND** (downsize node group) | Step 5 — reduce instance size or desired count |\n| Pod requests >> actual usage (requests\u002Fusage ratio > 2x) | **OPPORTUNITY_FOUND** (bin-packing) | Step 6 — reduce requests via VPA or manual tuning, then re-evaluate nodes |\n| Sporadic\u002Fdev workload on steady EC2 nodes with low pod density (\u003C 3 pods\u002Fnode) | **OPPORTUNITY_FOUND** (Fargate migration) | Step 4 — migrate to Fargate profile |\n| Steady-state, > 8 pods\u002Fnode, fault-tolerant, no PDB gap | **OPPORTUNITY_FOUND** (Spot node group) | Step 7 — Spot node group or Karpenter Spot capacity |\n| Cluster Autoscaler with empty\u002Funderutilized nodes | **OPPORTUNITY_FOUND** (Karpenter) | Step 8 — migrate to Karpenter for consolidation |\n| EC2 nodes at On-Demand pricing for steady-state baseline | **OPPORTUNITY_FOUND** (pricing model) | Step 9 — Compute Savings Plan |\n| Container Insights metrics absent (no observability) | **NEED_MORE_INFO** | Enable Container Insights, wait 14 days, re-evaluate |\n| All dimensions optimized: Karpenter + Spot + Savings Plan + tight requests | **ALREADY_OPTIMAL** | None — continue monitoring |\n| Post-remediation: changes applied and metrics confirm healthy utilization | **OPTIMIZED** | None — verification passed |\n\n## Pre-flight: data gate (run before any right-sizing decision)\n\n**Required data:** Container Insights node CPU\u002Fmemory utilization (14-30\nday window), pod-level usage for bin-packing analysis, node group\nconfiguration, and (optionally) `kubectl top nodes` for real-time signals.\nKey commands: `aws cloudwatch get-metric-statistics` for Container Insights\nmetrics, `kubectl top nodes` for live utilization, `kubectl describe node`\nfor allocatable resources.\n\nFull CLI sequences for data gathering are in\n`references\u002Feks-cost-reference.md` → \"Pre-flight data-gathering CLI commands\".\n\n### Data-quality short-circuits\n\n| Condition | Effect on optimization |\n|---|---|\n| Container Insights not enabled | **NEED_MORE_INFO**: Enable, wait 14 days. Do NOT recommend downsize without data. |\n| Observation window \u003C 14 days | **NEED_MORE_INFO**: may reflect atypical load. |\n| kubectl access unavailable (offline plan) | Rely on Container Insights. Mark bin-packing analysis MEDIUM confidence. |\n| Node group `DesiredSize: 0` (scaled to zero) | Skip — no cost to optimize. |\n| Fargate profile present but 0 running Fargate pods | Fargate charges per pod, not per profile. Skip. |\n\n### Conflicting-data arbitration\n\nWhen Container Insights and `kubectl top nodes` disagree, trust `kubectl\ntop nodes` (fresher, from the kubelet). When Container Insights and\nCloudWatch `AWS\u002FEC2` CPUUtilization disagree, trust Container Insights\n(`node_cpu_utilization` accounts for kubelet overhead).\n\n## Process — Optimization logic (apply in order)\n\n### Step 1: Validate input and data sufficiency\n\nIf Container Insights metrics (`node_cpu_utilization`,\n`node_memory_utilization`) are absent, emit NEED_MORE_INFO:\n\n```text\nTARGET: \u003Ccluster\u002Fnode-group>\nVERDICT: NEED_MORE_INFO\nREASON: Container Insights metrics are absent for this node group.\n  Without node CPU + memory utilization data, a node downsize\n  recommendation is a guess.\nRECOMMENDATION:\n  1. Enable Container Insights:\n     aws eks update-cluster-config --name \u003Ccluster> \\\n       --logging '{\"clusterLogging\":[{\"types\":[\"api\",\"audit\",\"authenticator\",\"controllerManager\",\"scheduler\"],\"enabled\":true}]}'\n  2. Verify metrics appear:\n     aws cloudwatch list-metrics --namespace ContainerInsights \\\n       --metric-name node_cpu_utilization \\\n       --dimensions Name=ClusterName,Value=\u003Ccluster>\n  3. Wait 14-30 days for representative data.\n  4. Re-evaluate.\nESTIMATED_SAVINGS: $0 (cannot quantify without utilization data)\n```\n\nIf the observation window \u003C 14 days, emit NEED_MORE_INFO. Proceed only if\ndata sufficiency passes.\n\n### Step 2: Node group inventory and current cost\n\nGather the node group configuration:\n\n```bash\naws eks describe-nodegroup --cluster-name \u003Ccluster> --nodegroup-name \u003Cng> \\\n  --output json | jq '{\n    instance_types: .nodegroup.instanceTypes,\n    desired: .nodegroup.scalingConfig.desiredSize,\n    min: .nodegroup.scalingConfig.minSize,\n    max: .nodegroup.scalingConfig.maxSize,\n    capacity_type: .nodegroup.capacityType,\n    ami_type: .nodegroup.amiType\n  }'\n```\n\nCompute current monthly node cost: `monthly = instance_hourly *\ndesired_size * 730`. Add the control plane cost ($73\u002Fmonth) pro-rated if\nanalyzing per-cluster.\n\n### Step 3: Bin-packing analysis (apply early)\n\nCheck whether pod `requests` are inflated relative to actual usage before\nright-sizing nodes:\n\n```bash\nkubectl get pods --all-namespaces -o json | jq '.items[] | {\n  pod: .metadata.name, cpu_request: .spec.containers[].resources.requests.cpu,\n  mem_request: .spec.containers[].resources.requests.memory}'\nkubectl top pods --all-namespaces\n```\n\n| Requests\u002Fusage ratio | Bin-packing verdict | Action |\n|---|---|---|\n| ratio \u003C 1.5x | Healthy | Proceed to node right-sizing (Step 5) |\n| ratio 1.5-3x | Moderate waste | Step 6 — reduce requests to p95 usage |\n| ratio > 3x | Severe waste | Step 6 — reduce requests FIRST, then re-evaluate nodes |\n\nIf ratio > 2x, node right-sizing is blocked on bin-packing — fix requests\nfirst. CLI commands in `references\u002Feks-cost-reference.md`.\n\n### Step 4: Fargate vs EC2 evaluation\n\n**Fargate recommended when:** pod density \u003C 3-4 per EC2 node, sporadic\nworkload, no DaemonSets\u002Fprivileged pods, zero node management desired.\n\n**EC2 recommended when:** steady-state with > 6 pods\u002Fnode, DaemonSets in\nuse, specific instance features needed (GPU, NVMe), Spot savings priority.\n\n**Fargate breakeven:**\n```\nfargate_pod_hourly = (vCPU_request * $0.04048) + (GB_request * $0.004445)\nec2_cost_per_pod = ec2_node_hourly \u002F ec2_pods_per_node\n# Fargate cheaper when fargate_pod_hourly \u003C ec2_cost_per_pod\n```\nFargate Spot offers up to 75% off for interruptible workloads.\n\n### Step 5: Node group right-sizing (after bin-packing is fixed)\n\n| Node utilization (30-day avg) | Action |\n|---|---|\n| CPU \u003C 30% AND Memory \u003C 50% | Downsize: reduce instance type by 1-2 sizes OR reduce desired count by 25-50%. |\n| CPU > 70% OR Memory > 80% | Upsize: increase instance type or desired count. |\n| 30-70% CPU, 50-80% Memory | Correctly sized. Proceed to Spot\u002Fpricing evaluation. |\n\n**Downsize:** Option A — create new node group with smaller type, drain\nold group, shift traffic (safer for production). Option B — update existing\ngroup's instance type (faster, rolling rescheduling).\n\n**Graviton:** requires multi-arch (arm64) container images. Types: m7g,\nc7g, r7g (up to 40% better price-performance).\n\n### Step 6: Bin-packing optimization (requests adjustment)\n\nReduce pod `requests` to match actual p95\u002Fp99 usage.\n\n| Resource | Recommendation rule |\n|---|---|\n| CPU request | p95 CPU usage over 30 days. Round up to nearest 25m. |\n| Memory request | p99 memory usage + 10-15% buffer (OOMKill risk). |\n| CPU limit | 2x request for burst workloads, or remove for latency-sensitive. |\n| Memory limit | >= request. A limit below request causes OOMKill. |\n\nAfter adjusting requests, re-evaluate node utilization (Step 5).\n\n### Step 7: Spot node group evaluation\n\n**Spot readiness checklist (ALL must pass):**\n1. Workload is stateless or tolerates graceful shutdown (2-min warning).\n2. PodDisruptionBudget configured for all deployments:\n   `kubectl get pdb --all-namespaces` — confirm `minAvailable` or\n   `maxUnavailable` set on every deployment.\n3. Graceful drain mechanism (NTH for Cluster Autoscaler; Karpenter native\n   disruption handling).\n4. Multi-AZ scheduling (topology spread constraints or anti-affinity) to\n   avoid correlated Spot interruptions.\n5. No stateful workloads (databases, queues) on Spot nodes — use\n   persistent EC2 On-Demand for stateful workloads.\n6. `terminationGracePeriodSeconds` set appropriately (default 30s; increase\n   for workloads needing graceful shutdown).\n\n**Recommendation:** Cluster Autoscaler → separate Spot node group + On-Demand\ngroup with selectors\u002Ftolerations. Karpenter → NodePool with Spot capacity\nand 3+ instance type alternatives.\n\n### Step 8: Cluster Autoscaler vs Karpenter evaluation\n\n| Dimension | Cluster Autoscaler | Karpenter |\n|---|---|---|\n| Scaling trigger | Pending pods | Pending pods + consolidation |\n| Consolidation | Only removes empty nodes | Removes empty + replaces underutilized nodes |\n| Spot handling | Requires NTH | Native disruption handling |\n| Instance flexibility | Constrained by node group config | Selects from instance type list automatically |\n| Typical savings | — | 20-40% over Cluster Autoscaler |\n\n**Recommendation:** If running Cluster Autoscaler with underutilized nodes\n(\u003C 40% CPU), migrating to Karpenter with consolidation enabled is typically\nthe highest-leverage single change.\n\n**Karpenter migration steps:**\n1. Install Karpenter via Helm.\n2. Create a NodePool with instance type alternatives and consolidation\n   enabled (`disruption.consolidationPolicy: WhenEmptyOrUnderutilized`).\n3. Cordon the Cluster Autoscaler-managed node group gradually.\n4. Karpenter provisions replacement nodes and consolidates.\n5. Remove Cluster Autoscaler once all workloads are on Karpenter nodes.\n\n### Step 9: Pricing model optimization\n\n| Node group pattern | Recommended model | Savings vs On-Demand |\n|---|---|---|\n| Steady-state On-Demand baseline | 3-year Compute Savings Plan | 50-72% |\n| Variable nodes (auto-scaling) | 1-yr CSP for baseline + On-Demand for spikes | 30-40% |\n| Spot-eligible burst nodes | Spot Instances | Up to 90% |\n| Fargate pods | No Savings Plan (not covered) | 0% (Fargate Spot: up to 75%) |\n\n**Commitment laddering:** commit a 1-3 year CSP for the steady-state EC2\nbaseline, use Spot for fault-tolerant burst, On-Demand for unpredictable spikes.\n\n### Step 10: Impact estimation and final verdict\n\n```\nBin-packing savings = freed_node_count * node_hourly * 730\nFargate migration savings = (ec2_cost - fargate_pod_cost) * 730\nSpot savings = (on_demand_hourly - spot_hourly) * node_count * 730\nKarpenter savings = (pre_nodes - post_nodes) * node_hourly * 730\nSavings Plan savings = committed_spend * discount_rate\n```\n\nVerdict: any dimension with a concrete recommendation → **OPPORTUNITY_FOUND**.\nAll dimensions pass + pricing optimized → **OPTIMIZED** or **ALREADY_OPTIMAL**.\nData insufficient → **NEED_MORE_INFO**.\n\n## Output format\n\nSee § STRICT output contract for the mandatory block. Worked example below.\nAdditional examples (Fargate migration, already optimal, NEED_MORE_INFO) in\n`references\u002Feks-cost-reference.md`.\n\n### Worked example — overprovisioned node group + bin-packing + Karpenter\n\n```text\nTARGET: prod-cluster\u002Fprod-general-purpose\nVERDICT: OPPORTUNITY_FOUND\nREASON: m5.2xlarge node group (4 nodes) at 12% CPU \u002F 25% Memory over 30 days\n  is overprovisioned. Root cause: pod requests inflated 4x vs actual usage.\n  Fix requests (Step 6), downsize to m7i.xlarge (Step 5), migrate to\n  Karpenter for consolidation (Step 8), and commit a 3-year Compute Savings\n  Plan on the reduced baseline (Step 9).\nRECOMMENDATION:\n  Current: m5.2xlarge x 4 nodes at On-Demand via Cluster Autoscaler\n  Proposed: m7i.xlarge x 2 nodes at 3-year Compute Savings Plan via Karpenter\n  Compute model: EC2 On-Demand → EC2 On-Demand (Karpenter-managed)\n  Autoscaler: Cluster Autoscaler → Karpenter (consolidation enabled)\n  Bin-packing action: reduce CPU requests from 4000m to 1000m per pod via VPA\n  Graviton: N\u002FA (some pods lack arm64 images; revisit after multi-arch build)\n  Confidence: HIGH — Container Insights reporting, kubectl top confirms low\n    usage, requests\u002Fusage ratio 4.2x (severe waste).\nESTIMATED_SAVINGS:\n  Monthly (right-size + bin-pack): $896.64  (m5.2xlarge $0.384\u002Fh x 4 →\n    m7i.xlarge $0.192\u002Fh x 2; 730h x $1.152 delta)\n  Monthly (Karpenter consolidation): $280.32  (estimated 30% further\n    node reduction from consolidation vs Cluster Autoscaler)\n  Monthly (pricing model): $112.22  (50% off m7i.xlarge On-Demand via\n    3-yr Compute Savings Plan on 2 nodes)\n  Annual total: $15,447.36\n  Assumptions: 730h\u002Fmonth, us-east-1 pricing, Karpenter consolidation\n    estimate is conservative (20-40% range).\nMIGRATION_STEPS:\n  1. Deploy VPA in recommend mode and review recommendations for top-20\n     pods by request\u002Fusage gap:\n     kubectl get vpa -n prod --output json | jq '.items[].status.recommendation'\n  2. Apply reduced CPU requests (4000m → 1000m) to deployments:\n     kubectl patch deployment \u003Cname> -n prod --type json \\\n       -p '[{\"op\":\"replace\",\"path\":\"\u002Fspec\u002Ftemplate\u002Fspec\u002Fcontainers\u002F0\u002Fresources\u002Frequests\u002Fcpu\",\"value\":\"1000m\"}]'\n  3. Install Karpenter and create a NodePool with m7i.xlarge as the\n     primary instance type and consolidation enabled:\n     helm install karpenter oci:\u002F\u002Fpublic.ecr.aws\u002Fkarpenter\u002Fkarpenter \\\n       -n karpenter --create-namespace\n     kubectl apply -f karpenter-nodepool.yaml\n  4. Cordon the old Cluster Autoscaler node group gradually (one node at\n     a time) and verify pods reschedule onto Karpenter nodes:\n     kubectl cordon \u003Cnode> && kubectl drain \u003Cnode> --ignore-daemonsets\n  5. Once all pods are on Karpenter nodes, delete the old node group:\n     aws eks delete-nodegroup --cluster-name prod-cluster \\\n       --nodegroup-name prod-general-purpose\n  6. Purchase a 3-year Compute Savings Plan for the m7i.xlarge baseline:\n     aws savingsplans create-savings-plan --savings-plan-offering-id \u003Cid> \\\n       --commitment \"\u003Chourly-amount>\"\nCONFIRM: Before installing Karpenter and cordoning nodes, emit and await:\n  \"CONFIRM: About to install Karpenter on prod-cluster and cordon the\n   prod-general-purpose node group. Pods will reschedule with brief\n   scheduling delays. Proceed? (yes\u002Fno)\"\n  Do NOT execute until the operator confirms.\n```\n\n## Verdict semantics\n\n| Verdict | When to emit |\n|---|---|\n| `OPPORTUNITY_FOUND` | At least one dimension has a concrete, savings-bearing recommendation. |\n| `OPTIMIZED` | Changes applied and verified this session; metrics confirm healthy bands. |\n| `ALREADY_OPTIMAL` | All dimensions optimized (Karpenter + Spot + Savings Plan + tight requests). |\n| `NEED_MORE_INFO` | Container Insights absent or observation window \u003C 14 days. Emit before any sizing recommendation. |\n| `BLOCKED` | Spot readiness check failed and the ONLY recommendation was Spot. |\n\n**Rule:** never emit `OPPORTUNITY_FOUND` without first discharging every\n`NEED_MORE_INFO` gate in Step 1.\n\n## Expert heuristic — consolidated\n\n| Heuristic | Impact on recommendation |\n|---|---|\n| Requests is the scheduling currency, not limits or usage | Check requests\u002Fusage ratio before node right-sizing. Inflated requests mask real utilization. |\n| Fargate does not support DaemonSets or privileged pods | Verify no DaemonSet dependencies before recommending Fargate. #1 migration blocker. |\n| Fargate charges per pod-request, not per pod-usage | Right-sizing the pod's own requests is the only Fargate lever. |\n| Spot gives 2-min warning; NTH\u002FKarpenter needed for graceful drain | Never recommend Spot without verifying PDB + drain mechanism. |\n| Karpenter consolidation deletes empty nodes AND replaces underutilized ones | Cluster Autoscaler only removes empty nodes. Replace mode is the 20-40% savings source. |\n| Graviton nodes need multi-arch container images | Verify arm64 manifest before recommending. Single-arch x86 fails on arm64. |\n| Compute Savings Plans cover EC2 nodes, NOT Fargate | Never claim Savings Plan savings on Fargate spend. |\n| Managed node group updates respect PDB | A PDB that blocks drainage stalls node group updates. |\n| Cross-AZ pod-to-pod traffic within a cluster is free | Right-sizing that changes AZ distribution does not add intra-cluster transfer cost. |\n| EKS control plane is $0.10\u002Fhour ($73\u002Fmonth) fixed | Node right-sizing does not reduce control plane cost. |\n| EKS Auto Mode bundles Karpenter-like provisioning | For new clusters, Auto Mode eliminates separate Karpenter installation. |\n| cluster-autoscaler never consolidates partially-used nodes | If nodes are 30% utilized but not empty, recommend Karpenter. |\n\n## NEVER (top 5 — full list in references)\n\n- NEVER recommend a node group downsize without first checking the pod\n  requests-to-usage ratio. Inflated requests produce pending pods.\n- NEVER recommend Fargate without verifying no DaemonSets, privileged pods,\n  or hostNetwork are in use. #1 Fargate migration failure.\n- NEVER recommend Spot without verifying PDB and graceful drain (NTH or\n  Karpenter). Without these, Spot interruptions cause data loss.\n- NEVER claim Compute Savings Plan savings on Fargate spend. CSPs apply to\n  EC2 instance spend only.\n- NEVER recommend a single instance type for a Spot node group or Karpenter\n  NodePool. Always provide 3+ alternative instance types.\n\n## Pre-flight safety checks (run before any remediation CLI)\n\n- **MANDATORY CONFIRMATION GATE** before any state-changing operation.\n- **Verify PDB before Spot migration:** `kubectl get pdb --all-namespaces`.\n- **Verify multi-arch images before Graviton:** `docker manifest inspect \u003Cimage>`.\n- **Verify no DaemonSet dependencies before Fargate:** `kubectl get ds --all-namespaces`.\n- **Drain nodes one at a time** during cutover.\n- **Batch limit:** max 3 node groups per batch, single CONFIRM, verify before next.\n- **Capture pre-state:** snapshot `describe-nodegroup` output before changes.\n\nFull detail in `references\u002Feks-cost-reference.md` → \"Pre-flight safety checks\".\n\n## Recent AWS features (2024-2026)\n\n- **EKS Auto Mode (2024-2025):** Managed compute auto-provisioning that\n  bundles Karpenter-like node management. Auto Mode handles instance\n  selection, Spot\u002FOn-Demand mix, and consolidation automatically. For new\n  clusters, Auto Mode eliminates the need to install Karpenter separately.\n\n- **Karpenter consolidation improvements (v0.32+, 2024-2025):** Disruption\n  budgets (`disruption.budgets`) allow rate-limiting consolidation to\n  control node churn in production. `WhenEmptyOrUnderutilized` is the\n  recommended consolidation policy for steady-state clusters.\n\n- **Graviton 4 (2024-2025):** Broad rollout across EKS-supported instance\n  types. Graviton 4 nodes offer up to 30% better performance than Graviton 3.\n\n- **Fargate pricing unchanged:** $0.04048\u002FvCPU-hour + $0.004445\u002FGB-hour\n  (us-east-1). Fargate Spot remains up to 75% off. Still not covered by\n  Compute Savings Plans (as of 2026).\n\n- **Compute Savings Plans enhancements (2024):** More flexible commitment\n  terms. Use for any EKS EC2 node baseline with uncertain workload growth.\n\n- **EKS Container Insights enhanced observability (2024-2025):** Per-pod\n  cost allocation via KubeCost integration. Recommended for FinOps-grade\n  cluster analysis.\n\n- **Spot Placement Score for EKS (2024-2025):** Predicts Spot capacity\n  availability before provisioning Spot node groups.\n\n## Domain\n\nAWS CloudOps \u002F EKS Kubernetes Compute Cost Optimization & FinOps.\n\n## AWS documentation\n\n- **Amazon EKS User Guide** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fwhat-is-eks.html\n- **EKS Pricing** — https:\u002F\u002Faws.amazon.com\u002Feks\u002Fpricing\u002F\n- **AWS Fargate Pricing** — https:\u002F\u002Faws.amazon.com\u002Ffargate\u002Fpricing\u002F\n- **EKS Managed Node Groups** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fmanaged-node-groups.html\n- **Karpenter** — https:\u002F\u002Fkarpenter.sh\u002F\n- **Container Insights** — https:\u002F\u002Fdocs.aws.amazon.com\u002FAmazonCloudWatch\u002Flatest\u002Fmonitoring\u002FContainer-Insights-metrics-EKS.html\n- **EKS Auto Mode** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fauto-mode.html\n- **Spot Instances for EKS** — https:\u002F\u002Fdocs.aws.amazon.com\u002Feks\u002Flatest\u002Fuserguide\u002Fspot.html\n- **PodDisruptionBudgets** — https:\u002F\u002Fkubernetes.io\u002Fdocs\u002Ftasks\u002Frun-application\u002Fconfigure-pdb\u002F\n- **AWS CLI EKS reference** — https:\u002F\u002Fdocs.aws.amazon.com\u002Fcli\u002Flatest\u002Freference\u002Feks\u002F\n- **AWS Well-Architected Framework — Cost Optimization** — https:\u002F\u002Fdocs.aws.amazon.com\u002Fwellarchitected\u002Flatest\u002Fcost-optimization-pillar\u002Fwelcome.html\n",{"name":5,"license":15,"metadata":24,"description":7,"compatibility":44},{"tags":25,"phase":26,"author":27,"domain":28,"family":29,"version":30,"keywords":31,"task_type":32,"complexity":33,"entry_point":34,"skill_class":35,"when_to_use":36,"requires_llm":37,"verdict_shape":38,"when_not_to_use":39,"lifecycle_status":40,"invocation_schema":41,"supports_pipeline":37,"invocation_example":42,"activation_triggers":43},"eks, kubernetes, compute, cost-optimization, finops, fargate, karpenter, spot","3","Jacky Chan — AWS Community Builder","aws-cloudops","Compute","0.1.0","EKS, Kubernetes, cost optimization, managed node group, Fargate, Spot Instances, Karpenter, Cluster Autoscaler, bin-packing, PodDisruptionBudget, requests, limits, Container Insights, Compute Savings Plans, FinOps, node group right-sizing, EKS Auto Mode, consolidation, Graviton, Vertical Pod Autoscaler","optimize","high","false","capability","Right-sizing EKS managed node groups for cost, evaluating Fargate vs EC2 for a workload, planning a Spot node group migration, comparing Cluster Autoscaler vs Karpenter, identifying bin-packing waste (requests vs limits gap), planning a Compute Savings Plan for EKS nodes, or building a monthly savings estimate for an EKS FinOps initiative.","true","OPTIMIZED | OPPORTUNITY_FOUND | ALREADY_OPTIMAL","Auditing a single pod's resource requests (use VPA recommendations directly), troubleshooting a pod crash or OOMKill (use kubectl describe and application logs), EC2 instance rightsizing outside EKS (use ec2-rightsizing-optimizer), EKS security or RBAC audits (use the security audit skills), or EKS upgrade planning (use the deploy\u002Foperate skills). This skill focuses on cost-driven EKS optimization decisions.","active","Input: either (a) an EKS cluster identifier + live-account context, (b) a managed node group configuration with utilization data, OR (c) Container Insights metrics (node CPU, node memory, pod CPU, pod memory) for one or more node groups with at least 14 days of observation. Output: a deterministic TARGET\u002FVERDICT\u002FREASON\u002FRECOMMENDATION\u002FESTIMATED_SAVINGS\u002F MIGRATION_STEPS block per node group or cluster, where VERDICT is one of {OPTIMIZED, OPPORTUNITY_FOUND, ALREADY_OPTIMAL} and RECOMMENDATION includes the target node type, compute model (EC2\u002FFargate\u002FSpot), autoscaler strategy, and pricing model.","# Minimal valid input (offline finding classification):\nCluster: prod-cluster\nRegion: us-east-1\nNode group: prod-general-purpose\nInstance type: m5.2xlarge\nDesired size: 4 nodes (min 3, max 10)\nCompute model: EC2 On-Demand managed node group\nAutoscaler: Cluster Autoscaler\nUtilization (Container Insights, last 30 days):\n  - node_cpu_utilization: avg=12%, max=20%\n  - node_memory_utilization: avg=25%, max=35%\n  - Average pods per node: 8 (capacity ~30)\nWorkload: mixed microservices (Java, Python, Go), multi-arch\nDocker images available.\nEmit the standard optimization block.","optimize EKS cluster cost, right-size EKS node group, Fargate vs EC2 nodes, EKS Spot Instance node group, Karpenter vs Cluster Autoscaler, Karpenter consolidation savings, EKS bin-packing optimization, Kubernetes requests vs limits, EKS Compute Savings Plan, EKS FinOps savings, reduce EKS node spend, EKS Graviton node group, EKS Auto Mode cost, EKS node group downsize, Kubernetes cost optimization","Agent runtime that reads SKILL.md (Claude Code, Cursor, Windsurf, Codex, Gemini). Offline recommendation classification works from pasted Container Insights metrics and node group configurations. Live-account optimization uses aws eks describe-nodegroup, aws eks list-fargate-profiles, aws cloudwatch get-metric-statistics, aws ce get-cost-and-usage, aws ec2 describe-instance-types, and aws ce get-savings-plans-coverage (AWS CLI v2, SSO or key-based credentials). kubectl top nodes \u002F kubectl...","main","eeace51bd5dd1db2030729d83eeab988861553aa","skills\u002Feks-cost-optimizer",0,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills","https:\u002F\u002Fgithub.com\u002Fjhkchan","CTO & Co-Founder @Beever-AI  & @votee. CAISP. AWS Community Builder. Organizer@GDGCloudHK. MongoDB Champion. Technopreneur + Infornographer.","2026-09-24 08:54:10",{"source":8,"skillName":5,"commands":54,"prompt":64,"zipAvailable":65},[55,58,61],{"tool":56,"command":57},"npx","npx skills add jhkchan\u002Faws-agent-skills --skill eks-cost-optimizer",{"tool":59,"command":60},"bunx","bunx skills add jhkchan\u002Faws-agent-skills --skill eks-cost-optimizer",{"tool":62,"command":63},"pnpm","pnpm dlx skills add jhkchan\u002Faws-agent-skills --skill eks-cost-optimizer","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002FSKILL.md",true,[67,73,77,81,85,89,93,97,101,105,109,113,117,121,125,129],{"path":68,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":71,"sourceHtmlUrl":72},"eval\u002Ftest-cases.yaml","REFERENCE","参考文档",8788,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Feval\u002Ftest-cases.yaml",{"path":74,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":75,"sourceHtmlUrl":76},"evals\u002Fbaselines\u002Falready-optimal-karpenter-savings-plan.md",636,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fbaselines\u002Falready-optimal-karpenter-savings-plan.md",{"path":78,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":79,"sourceHtmlUrl":80},"evals\u002Fbaselines\u002Fbin-packing-requests-limits-waste.md",730,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fbaselines\u002Fbin-packing-requests-limits-waste.md",{"path":82,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":83,"sourceHtmlUrl":84},"evals\u002Fbaselines\u002Ffargate-vs-ec2-scheduling-mismatch.md",597,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fbaselines\u002Ffargate-vs-ec2-scheduling-mismatch.md",{"path":86,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":87,"sourceHtmlUrl":88},"evals\u002Fbaselines\u002Fnode-group-overprovisioned-downsize.md",886,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fbaselines\u002Fnode-group-overprovisioned-downsize.md",{"path":90,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":91,"sourceHtmlUrl":92},"evals\u002Fbaselines\u002Fspot-node-group-missing-pdb.md",661,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fbaselines\u002Fspot-node-group-missing-pdb.md",{"path":94,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":95,"sourceHtmlUrl":96},"evals\u002Feval_config.yaml",1867,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Feval_config.yaml",{"path":98,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":99,"sourceHtmlUrl":100},"evals\u002Fevals.json",4629,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fevals.json",{"path":102,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":103,"sourceHtmlUrl":104},"evals\u002Fprompts\u002Falready-optimal-karpenter-savings-plan.md",1003,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fprompts\u002Falready-optimal-karpenter-savings-plan.md",{"path":106,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":107,"sourceHtmlUrl":108},"evals\u002Fprompts\u002Fbin-packing-requests-limits-waste.md",971,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fprompts\u002Fbin-packing-requests-limits-waste.md",{"path":110,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":111,"sourceHtmlUrl":112},"evals\u002Fprompts\u002Ffargate-vs-ec2-scheduling-mismatch.md",794,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fprompts\u002Ffargate-vs-ec2-scheduling-mismatch.md",{"path":114,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":115,"sourceHtmlUrl":116},"evals\u002Fprompts\u002Fnode-group-overprovisioned-downsize.md",970,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fprompts\u002Fnode-group-overprovisioned-downsize.md",{"path":118,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":119,"sourceHtmlUrl":120},"evals\u002Fprompts\u002Fspot-node-group-missing-pdb.md",989,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fevals\u002Fprompts\u002Fspot-node-group-missing-pdb.md",{"path":122,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":123,"sourceHtmlUrl":124},"examples\u002FREADME.md",6587,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fexamples\u002FREADME.md",{"path":126,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":127,"sourceHtmlUrl":128},"references\u002Feks-cost-reference.md",20050,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Freferences\u002Feks-cost-reference.md",{"path":130,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":131,"sourceHtmlUrl":132},"skill.usf.yaml",4473,"https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Feks-cost-optimizer\u002Fskill.usf.yaml",[134,141,148,155,162,169],{"skillNo":135,"name":136,"nameZh":6,"description":137,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":138,"categories":139,"keywords":140,"publishedAt":19},"01M7ADVD60X4PCAPKSE58P9NDC","xray-tracing-deployer","Deploys AWS X-Ray distributed tracing with production-grade configuration: X-Ray daemon deployment (EC2 systemd, ECS sidecar, EKS DaemonSet, Lambda built-in), SDK instrumentation (Java, Python, Node.js, Go, .NET) with annotations and metadata, sampling rules (default reservoir + rate vs custom rules with URL \u002F method \u002F service-name predicates), service map generation, trace query and retrieval, groups and insights, CloudWatch ServiceLens integration, IAM permissions (PutTraceSegments, GetSamplingRules), and latest features (Lambda Powertools tracing, OpenTelemetry \u002F ADOT Collector support, W3C trace context). Emits a READY_TO_DEPLOY checklist with every configuration item verified. Use when enabling X-Ray on a new application, adding tracing to ECS \u002F EKS \u002F Lambda, validating a sampling configuration, or generating daemon deployment CLI and IaC templates. Triggers: X-Ray, distributed tracing, X-Ray daemon, sampling rules, service map, X-Ray SDK, OpenTelemetry, ADOT, Lambda Powertools, CloudWatch ServiceLens.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fxray-tracing-deployer\u002FSKILL.md",[],[],{"skillNo":142,"name":143,"nameZh":6,"description":144,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":145,"categories":146,"keywords":147,"publishedAt":19},"01M7ADTVJ7DCBM9CB1FY51GH7J","wellarchitected-workload-auditor","Audits AWS Well-Architected Tool workloads for review staleness, per-pillar high-risk issue counts, milestone tracking gaps, and remediation plan completeness. Emits a deterministic verdict (STALE_REVIEW | HIGH_RISK | CONFIG_GAP | OK) per workload with per-pillar risk breakdown, milestone trend analysis, and specific remediation. Use when reviewing Well-Architected workloads, checking WA review freshness, auditing high-risk issues per pillar, validating milestone coverage, or tracking remediation plans.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fwellarchitected-workload-auditor\u002FSKILL.md",[],[],{"skillNo":149,"name":150,"nameZh":6,"description":151,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":152,"categories":153,"keywords":154,"publishedAt":19},"01M7ADT59G6FTTNZYHT2QRPNNP","wellarchitected-review-operator","Operates AWS Well-Architected Tool reviews end-to-end — creates workloads, runs pillar reviews (operational excellence, security, reliability, performance, cost optimization, sustainability, Prosperity), answers questions with risk-tier rationale, generates reports and improvement plans, creates milestones, and integrates with Trusted Advisor and Well-Architected Labs. Runs deterministic pre-checks (workload existence, lens availability, pillar coverage), emits the exact update-answer \u002F get-consolidated-report CLI behind a CONFIRM gate, and verifies risk-tier transitions. Emits READY | BLOCKED | COMPLETED. Use when creating a workload, answering pillar questions, generating an improvement plan, creating a milestone, or integrating with Trusted Advisor. Triggers: well-architected tool, well architected review, workload review, pillar, operational excellence, security, reliability, performance, cost optimization, sustainability, prosperity, improvement plan, milestone, trusted advisor.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fwellarchitected-review-operator\u002FSKILL.md",[],[],{"skillNo":156,"name":157,"nameZh":6,"description":158,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":159,"categories":160,"keywords":161,"publishedAt":19},"01M7ADSH5JA9QHNPPHQCD7EVA7","wafv2-web-acl-deployer","Provisions AWS WAFv2 Web ACLs with correct production defaults: scope selection (CLOUDFRONT vs REGIONAL), managed rule groups (AWSManagedRulesCommonRuleSet, SQLiRuleSet, LinuxRuleSet, WindowsRuleSet, IPReputationList, BotControlRuleSet, AmazonIpReputationList, ATP), custom rules (byte match, IP set, regex pattern, geo match, size constraint, rate-based), rule priority ordering, logging destinations (Kinesis Firehose, CloudWatch Logs, S3), resource association (ALB, API Gateway, CloudFront), rate-based rules with aggregate keys (IP, forwarded IP), Challenge and CAPTCHA actions, and account takeover prevention. Emits a READY_TO_DEPLOY checklist. Use when creating a Web ACL, attaching managed rules, configuring rate limiting, enabling WAF logging, associating a Web ACL with an ALB\u002FAPI Gateway\u002FCloudFront, or configuring CAPTCHA\u002FChallenge actions. Triggers: create WAF Web ACL, WAFv2, managed rule groups, WAF rate limiting, WAF logging, WAF CAPTCHA, WAF Challenge action, bot control, ATP managed rules.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fwafv2-web-acl-deployer\u002FSKILL.md",[],[],{"skillNo":163,"name":164,"nameZh":6,"description":165,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":166,"categories":167,"keywords":168,"publishedAt":19},"01M7ADRYFAT8R73FBNCHRC573X","wafv2-web-acl-auditor","Audits AWS WAFv2 Web ACL configurations to determine whether the ACL provides effective protection: default-action posture (Allow vs Block), managed-rule-group coverage gaps, rule effectiveness (BLOCK vs COUNT, shadow\u002Fbypass rules, stale exclusions), rate-based rule correctness, logging and visibility configuration, and text-transformation bypass vectors. Emits a deterministic verdict per Web ACL. Use when reviewing a WAFv2 Web ACL for security posture, checking managed-rule coverage, validating rate-limit configuration, auditing WAF logging, or hardening a WAF before production deployment. Triggers: WAF, WAFv2, Web ACL, managed rule group, AWSManagedRules, rate-based rule, CAPTCHA, Challenge, OverrideAction, Count mode, forwarded IP, Bot Control, ATP, text transformation, WAF logging, WAF visibility, OWASP, SQLi, XSS, RFI.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fwafv2-web-acl-auditor\u002FSKILL.md",[],[],{"skillNo":170,"name":171,"nameZh":6,"description":172,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":173,"categories":174,"keywords":175,"publishedAt":19},"01M7ADR8W7G72JX4KFGN03QK8Q","waf-rule-deployer","Provisions AWS WAFv2 rule sets with production defaults: Web ACL creation (CloudFront scope in us-east-1 vs Regional scope), rule groups (managed vs custom) with capacity planning in WCU (Web ACL Capacity Units, 1500 default per ACL), managed rule groups (AWSManagedRulesCommonRuleSet, AWSManagedRulesSQLiRuleSet, AWSManagedRulesAmazonIpReputationList, AWSManagedRulesLinuxRuleSet, AWSManagedRulesWindowsRuleSet, AWSManagedRulesUnixRuleSet), custom rules (byte-match, regex pattern set, geo-match, rate-based), IP set and regex pattern set resources, rule priority ordering (lowest number evaluated first), action types (allow, block, count, CAPTCHA, Challenge), bot control managed rule group, account takeover. Triggers: create WAF rule, WAF managed rule group, WAF custom rule, WAF byte match, WAF geo match, WAF rate based rule, WAF IP set, WAF regex pattern set, WAF WCU budget, WAF CloudFront ACL, WAF logging Kinesis Firehose, WAF bot control, WAF ATP, WAF label matching, WAF Challenge action, WAF CAPTCHA.","https:\u002F\u002Fgithub.com\u002Fjhkchan\u002Faws-agent-skills\u002Fblob\u002Fmain\u002Fskills\u002Fwaf-rule-deployer\u002FSKILL.md",[],[]]