From sre-extension
Sets up read-only Service Accounts for GCP and Kubernetes investigations, provides safe_gcloud and safe_kubectl wrappers, and includes risk assessments for suggested commands.
How this skill is triggered — by the user, by Claude, or both
Slash command
/sre-extension:safe-sre-investigatorThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
This skill helps set up and use dedicated read-only Service Accounts for investigating GCP and Kubernetes resources.
This skill helps set up and use dedicated read-only Service Accounts for investigating GCP and Kubernetes resources.
It provides wrapper scripts safe_gcloud and safe_kubectl to ensure commands are run with these limited-privilege accounts.
When suggesting commands, it includes a risk assessment.
safe_gcloud script.safe_kubectl script for a specific cluster.gcloud or kubectl commands with risk assessments.safe_gcloud)When first using this skill for a project, or if the user asks for setup, guide them through the one-time setup process for GCP access.
Action: Ask the user for the Project ID.
Script: Run the setup script:
bash ./scripts/setup_safe_sre_investigator.sh PROJECT_ID
~/bin/safe_gcloud.references/iam_roles.md.safe_kubectl)This setup must be run for EACH Kubernetes cluster you want to investigate.
Action: Ask the user for the Cluster Name and Cluster Location (Zone or Region).
Script: Run the setup script:
bash ./scripts/setup_safe_kubectl.sh CLUSTER_NAME CLUSTER_LOCATION
~/.kube/safe-investigator-configs/.~/bin/safe_kubectl.references/k8s_readonly_role.yaml.When the user asks for a command:
safe_gcloud PROJECT_ID <gcloud commands>.safe_kubectl CLUSTER_NAME -- <kubectl commands>.references/risk_assessment.md.gcloud or kubectl command and warn the user to run it with their own credentials, noting the risks.Example safe_gcloud:
# 🎬 Check GKE cluster status
# ⚠️ Risk: ⚪ NONE: This is a read-only operation.
safe_gcloud my-project container clusters list
Example safe_kubectl:
# 🎬 List pods in the default namespace
# ⚠️ Risk: ⚪ NONE: This is a read-only operation.
safe_kubectl my-cluster -- get pods -n default
scripts/setup_safe_sre_investigator.sh: GCP setup.scripts/safe_gcloud_wrapper.sh: Template for ~/bin/safe_gcloud.scripts/setup_safe_kubectl.sh: Kubernetes setup.scripts/safe_kubectl_wrapper.sh: Template for ~/bin/safe_kubectl.references/iam_roles.md: GCP IAM roles.references/k8s_readonly_role.yaml: Kubernetes ClusterRole definition.references/risk_assessment.md: Risk assessment format.npx claudepluginhub gemini-cli-extensions/sre --plugin sre-extensionAudits Kubernetes RBAC configurations for overly permissive roles, wildcard permissions, dangerous bindings, service account abuse, and privilege escalation using kubectl, rbac-tool, KubiScan, Kubeaudit. For cluster security assessments on EKS, GKE, AKS.
Audits Kubernetes RBAC for overly permissive roles, wildcards, dangerous bindings, service account abuse, and privilege escalation using kubectl, rbac-tool, KubiScan, and Kubeaudit.
Verifies and harmonizes Google Cloud authentication across gcloud, Application Default Credentials, and kubectl at session start.