# Check Secrets

> Verify secrets and configmaps in a namespace. Use for deployment config verification, debugging missing env vars, or auditing secret presence.

- Skill: `dmzoneill/check-secrets` (Agent Skill)
- Install (CLI): `npx skillmds@latest add dmzoneill/check-secrets`
- Raw SKILL.md: https://api.skillmd.com/api/skills/dmzoneill/check-secrets/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Security
- Author: dmzoneill (https://skillmd.com/u/dmzoneill)
- Updated: 2026-09-10
- Page: https://skillmd.com/skills/dmzoneill/check-secrets

---


# Check Secrets

Verify secrets and configmaps are properly configured in a namespace.

## Inputs

| Input | Type | Default | Purpose |
|-------|------|---------|---------|
| `namespace` | string | required | Kubernetes namespace |
| `environment` | string | stage | stage, production, ephemeral |
| `deployment` | string | "" | Optional: specific deployment to check references |

## Workflow

### 1. Load Persona
- `persona_load("devops")`

### 2. List Resources
- `kubectl_get_secrets(namespace="{{ namespace }}", environment="{{ environment }}")`
- `kubectl_get_configmaps(namespace="{{ namespace }}", environment="{{ environment }}")`

### 3. Check Deployment References (if deployment specified)
- `kubectl_describe_deployment(deployment="{{ deployment }}", namespace="{{ namespace }}", environment="{{ environment }}")`
- Parse for `secretKeyRef`, `configMapKeyRef`, `secretRef`, `configMapRef`
- Compare referenced names to existing secrets/configmaps

### 4. Report Missing
- If deployment references missing: list missing secrets and configmaps

### 5. Error Recovery
- "unauthorized" → `kube_login(cluster="stage" or "prod")`
- "no route to host" → `vpn_connect()`

### 6. Memory
- `memory_session_log("Checked secrets and configmaps", "namespace={{ namespace }}, secrets={{ count }}")`

## Output

Report: secrets list (name, type), configmaps list, deployment references (if specified), and any missing resources.

