agentleFS
selamy-labsselamy-labs/agent-skills/skills/iac-incident-response/SKILL.md

iac-incident-response

Skill0 starsChanged 7 days agoMITView on GitHub

Use during infrastructure outages when fixes must preserve declarative source of truth instead of leaving live manual drift behind.

The file

We split this skill into the rules it gives an agent

9 rules. About 0 are common, 9 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this when infrastructure is broken and there is pressure to fix it directly.

    line 8
  2. Distinctive:

    Prefer a source change, merge, and apply over direct mutation.

    line 14
  3. Distinctive:

    If an emergency manual resource exists, import it into state or replace it through a declared resource before declaring recovery complete.

    line 15
  4. Distinctive:

    Do not bridge a branch by hand-applying manifests that the main branch does not own.

    line 17
  5. Distinctive:

    If live state already changed, reconcile it:

    line 30
  6. Distinctive:

    import hand-made resources into state, or

    line 31
  7. Distinctive:

    remove them only after the declared replacement is ready.

    line 32
  8. Distinctive:

    Run a no-drift check after recovery:

    line 33
  9. Distinctive:

    Read-only cloud, cluster, and CI commands are fine.

    line 41

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

IaC Incident Response

Use this when infrastructure is broken and there is pressure to fix it directly. The goal is fast recovery without creating hidden state that the next apply will destroy or fail to reproduce.

Rules

  • Prefer a source change, merge, and apply over direct mutation.
  • If an emergency manual resource exists, import it into state or replace it through a declared resource before declaring recovery complete.
  • Do not bridge a branch by hand-applying manifests that the main branch does not own.
  • Escalate the precise blocker rather than bypassing the source of truth.

Incident Workflow

  1. Identify the failed declarative boundary:
    • infrastructure plan/apply
    • GitOps sync
    • controller reconciliation
    • CI secret/config propagation
  2. Make the smallest source change that lets the normal reconciler fix the system.
  3. If live state already changed, reconcile it:
    • import hand-made resources into state, or
    • remove them only after the declared replacement is ready.
  4. Run a no-drift check after recovery:
    • plan shows no unexpected changes, or expected changes are reviewed
    • GitOps reports synced/healthy
    • a real workload or workflow proves the path works
  5. Capture the guard that would have caught the failure earlier.

Acceptable Diagnostics

Read-only cloud, cluster, and CI commands are fine. They become unsafe when they turn into live patching, deleting, scaling, or secret mutation without a matching source change.

Done

  • A fresh apply or sync can reproduce the recovered state.
  • Manual emergency resources are gone or imported.
  • The incident report names any remaining external blocker.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.