gke-stockout-investigator

gke-stockout-investigator is a skill for Claude Code, Codex from gke-labs/kube-agents. It costs 34 tokens per session (5,394 once invoked), scanned B, original, Apache-2.0.

A runbook for investigating GKE capacity stockout alerts. GKE is Google Kubernetes Engine, a service that runs containerized applications; a stockout means the cluster cannot obtain enough compute capacity.

In plain words
What is it for?
It helps respond to Pub/Sub alerts, investigate ComputeClass-related capacity problems, and prepare a remediation pull request.
Why use it?
It gives a defined process for diagnosing why workloads cannot scale and submitting a fix through a Git-based change request.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ./skills/submit-suggestion/scripts/submit_suggestion.py prepare \.

Good fit It helps respond to Pub/Sub alerts, investigate ComputeClass-related capacity problems, and prepare a remediation pull request.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/gke-labs/kube-agents
agentmods
npx agentmods add skills/gke-labs/kube-agents/gke-stockout-investigator

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for gke-stockout-investigator

README.md
[![agentmods](https://agentmods.dev/badge/skills/gke-labs/kube-agents/gke-stockout-investigator/github.svg)](https://agentmods.dev/skills/gke-labs/kube-agents/gke-stockout-investigator)
Your own site
<a href="https://agentmods.dev/skills/gke-labs/kube-agents/gke-stockout-investigator"><img src="https://agentmods.dev/badge/skills/gke-labs/kube-agents/gke-stockout-investigator/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for gke-stockout-investigator

Your own site · 80×15
<a href="https://agentmods.dev/skills/gke-labs/kube-agents/gke-stockout-investigator"><img src="https://agentmods.dev/badge/skills/gke-labs/kube-agents/gke-stockout-investigator.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,394 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Excessive Agency · line 287
    Skill grants unrestricted tool access without appropriate constraints. An agent with unfettered tool access can perform arbitrary actions including file modification, network requests, and code execution.
    Fix: Restrict tool access to only the tools required for the skill's stated purpose. Use an explicit allowlist rather than granting blanket access.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00034 $0.05394
Opus 5 $0.00017 $0.02697
Sonnet 5 $0.00007 $0.01079
Haiku 4.5 $0.00003 $0.00539

Measured today against content hash 7f2b44458f57, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade B, and why

gke-stockout-investigator scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Unrestricted tool accessmediumExcessive agency

A wildcard tool grant or "run any command" leaves no least-privilege boundary at all.

When running in a background/PubSub context or when a new SRE review Pull Request with remediation is being created, before providing your final response, you MUST call the `send_notification` tool to notify the user/SRE

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

> In background/PubSub sessions, any invocation of `execute_code` (Python or bash script execution) triggers interactive command approval safeguards that will block and hang the session indefinitely. You MUST execute com
agentplugins/gke-stockout-investigator/files/skills/gke-stockout-investigator/SKILL.md · 304 lines

How it starts

The opening of the file, as written. The whole thing — 304 lines — stays where its author put it; the contents beside it link to each section on GitHub.

GKE Stockout Diagnosis & GitOps Remediation Skill

This skill guides the Platform Agent on how to handle, diagnose, and remediate GKE capacity stockout alerts (scale.up.error.out.of.resources or equivalent) received via Google Cloud Pub/Sub.

Workflow

1. Notify User of Investigation Start (MANDATORY FIRST STEP)

Before executing ANY terminal commands, scripts, or diagnostics, you MUST immediately call the send_notification tool (or mcp_platform_control_send_notification) to announce that the stockout alert was received and investigation is starting:

send_notification(message="🚨 GKE Stockout Investigation Started\nWorkload: <workload_name>\nCluster: <cluster_name>\nDetails: A GKE capacity stockout alert is confirmed. I am starting an investigation and diagnosis.")

CRITICAL: You MUST invoke send_notification (or mcp_platform_control_send_notification) as an actual tool call. Do NOT output this notification as plain markdown text. After calling the tool, proceed immediately to Step 2 in your next tool turn without stopping.

[!IMPORTANT] When running in a background or PubSub context, NEVER use the execute_code tool or write Python scripts/subshells, as they trigger command approval safeguards and block indefinitely waiting for human approval. Only execute standard command-line tools directly (kubectl, gh, gcloud) or dedicated tools like send_notification.

2. Pre-Diagnosis Verifications (Duplicate PRs & False Signal Checks)

After sending the initial notification, perform two critical safety checks to see if you should stop immediately:

A. Check for Existing Relevant Pull Requests (Duplicate Prevention)

To prevent duplicate effort and redundant PRs, inspect currently open Pull Requests in the repository:

  1. Resolve the GitOps repository as <owner>/<repo>, and name it on every gh call from here on. The pod is not a git checkout (Step 3 explains why), so gh has no origin remote to infer a repository from: an unqualified gh pr list fails on repository resolution rather than returning a list, and the duplicate check silently never happens. Query the $GITOPS_STATE_CONFIGMAP ConfigMap:

Read the full file on GitHub · 304 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today Changed · +10 lines 7f2b44458f57
  2. 9d ago Changed · +1 lines 81ca6031a604
  3. 12d ago First seen · 293 lines · 34 tokens per session scan B 7babea5cfbfa

Subscribe to this mod's changes

gke-stockout-investigator is a skill published in the GitHub repository gke-labs/kube-agents (54 stars, last pushed today), licensed Apache-2.0. It adds 34 tokens to every session and 5,394 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it B with 2 findings (unrestricted tool access, runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

gke-ai-troubleshooting-jobset-interruption

Diagnoses GKE JobSet interruptions, restarts, and preemptions for AI/ML training workloads autonomously. Use when troubleshooting JobSet restart loops, spot VM preemptions, node readiness failures, host VM issues, or coordinator worker crashes. Don't use for general GKE cluster creation, basic workload deployment, or…

google/skills · 83 tokens

gke-workload-troubleshooting

Diagnoses GKE workload failures (CrashLoopBackOff, OOMKilled, ImagePullBackOff, Pending, etc.) via logs and events. Use when pods fail to start or crash repeatedly. Don't use for GKE cluster infrastructure provisioning, node pool creation, or non-Kubernetes Google Cloud services.

google/skills · 69 tokens

gke-node-notready

Diagnoses GKE nodes reporting NotReady or Unknown status by inspecting node conditions, events, kubelet/containerd logs, and node metrics, then proposing safe remediations. Use when nodes show NotReady, when the kubelet stops posting node status, or when workloads are evicted or stuck Pending due to node health. Don't…

google/skills · 112 tokens

gke-ai-troubleshooting-handle-disruption-gpu-tpu

Diagnoses, predicts, and mitigates node disruptions during Compute Engine host maintenance and hardware or software maintenance events for GPU and TPU workloads on GKE. Use when diagnosing node disruptions, predicting host maintenance events on GPU/TPU nodepools, inspecting node interruption PromQL metrics, auditing…

google/skills · 117 tokens

agentcore-investigation

Investigate Bedrock AgentCore runtime sessions via CloudWatch Logs Insights — resolve session/trace IDs, query OTEL spans, filter noise, build timelines. Use when debugging AgentCore agent sessions, tracing tool calls, or analyzing latency.

awslabs/mcp · 52 tokens

troubleshoot-sandbox

Troubleshoot OpenSandbox issues by running diagnostics (logs, inspect, events, summary) via CLI or HTTP API to diagnose sandbox failures like OOM, crash, image pull errors, network problems, etc.

opensandbox-group/OpenSandbox · 48 tokens