К основному содержанию
скилл Claude Code

chaos-engineering — скилл для Claude Code: как установить

Скилл помогает планировать контролируемые сбои в продакшене, рассчитывать радиус поражения и готовить постмортемы. Пригодится при подготовке учений Game Day и проверке отказоустойчивости.

Установить в Claude Code · Через маркетплейс плагинов Все способы и платформы ↓
/plugin marketplace add alirezarezvani/claude-skills
/plugin install chaos-engineering@claude-code-skills
Открыть на GitHub

Что делает chaos-engineering

Скилл добавляет слэш-команду /chaos-experiment и справочники по семи типам атак. Внутри три скрипта на чистом Python без сторонних библиотек. Скрипт experiment_designer.py формирует план проверки с обязательными критериями отката. Утилита blast_radius_calculator.py оценивает затронутый трафик, а experiment_postmortem.py собирает итоговый отчёт.

Хаос без критериев остановки превращается в аварию. Поэтому скилл требует заранее фиксировать базовое состояние системы и правила отката. Для запуска инструментов нужен установленный Python со стандартной библиотекой. Решение связывается со скиллами feature-flags-architect и kubernetes-operator.

Ставьте его командам надежности для плановых стресс-тестов. Для расследования уже случившихся инцидентов он не подойдет.

Какие задачи решает

  • рассчитать радиус поражения и сгорание бюджета ошибок до старта эксперимента
  • составить план внедрения сбоев с метриками отката и базового состояния
  • сформировать структурированный постмортем без поиска виновных
  • подобрать инструмент между Chaos Toolkit, Chaos Mesh, Litmus, Gremlin и AWS FIS

Примеры запросов агенту

  • Помоги спланировать эксперимент с задержками для сервиса checkout-svc
  • /chaos-experiment
  • Рассчитай blast radius, если затронуто 0.05 трафика сервиса

Как установить chaos-engineering

1Через маркетплейс плагинов

/plugin marketplace add alirezarezvani/claude-skills
/plugin install chaos-engineering@claude-code-skills

Команда ставит плагин chaos-engineering целиком, со всеми его скиллами

2Через Skills CLI (Vercel)

npx skills add alirezarezvani/claude-skills --skill chaos-engineering -a claude-code

3Вручную: положить файлы

~/.claude/skills/chaos-engineering/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/chaos-engineering/

Из того же набора349

Весь набор →
engineering-skills Alireza Rezvani Каталог инженерных скиллов для Claude Code: помогает выбрать роль под задачу и загрузить только нужный SKILL.md. Подходит для архитектуры, тестов, DevOps и работы с данными. Claude Code 2 387установок finance-skills Alireza Rezvani Маршрутизирует финансовые запросы между тремя скиллами бандла: financial-analyst, saas-metrics-coach и month-end-close. Claude Code 2 312установок marketing-skills Alireza Rezvani Каталог и роутер для маркетинговых скиллов в Claude Code. Помогает выбрать нужный скилл для SEO, контента, CRO, каналов и других задач. Claude Code 2 264установок business-growth-skills Alireza Rezvani Маршрутизирует запросы по продажам и клиентскому сервису между четырьмя специализированными скиллами плагина в Claude Code. Claude Code 2 189установок engineering-advanced-skills Alireza Rezvani Индекс из 37 инженерных скиллов для архитектуры, автоматизации, надёжности и платформенных задач. Пригодится, когда проекту нужны отдельные рабочие сценарии. Claude Code 2 019установок product-skills Alireza Rezvani Оркестратор продуктовой работы для Claude Code. Маршрутизирует задачи между 16 направлениями и проверяет дерево возможностей скриптами. Claude Code 1 994установок pm-skills Alireza Rezvani Оркестрирует проектную работу через 8 PM-скиллов: Jira, Confluence, спринты, отчёты и коммуникации. Подходит для маршрутизации запросов и контроля delivery-цикла. Claude Code 1 975установок senior-backend Alireza Rezvani Скилл помогает проектировать архитектуру бэкенда, настраивать REST API и оптимизировать базы данных. Пригодится при создании роутов, ревью кода и нагрузочном тестировании. Claude Code 1 674установок

Похожие

dotnet-mcp-builder официальный github Скилл помогает создавать MCP-серверы и базовые клиенты на C#/.NET с пакетами ModelContextProtocol 2.x. Подключайте его, когда добавляете MCP-инструменты в .NET-проект. GitHub Copilot 152установок acreadiness-policy официальный github Помогает настраивать, создавать и применять политики проверок готовности AgentRC. Пригодится при настройке strict-режима, фильтрации проверок и гейтинге в CI. GitHub Copilot 133установок wizard Matt Pocock Скилл создаёт интерактивный bash-скрипт для ручных шагов: настройки сервисов, секретов CI и разовых миграций. Claude Code 553 369установок hyperframes-cli heygen-com Управляет проектами HyperFrames через терминал: собирает таймлайн, проверяет контраст кадров, запускает предпросмотр и рендерит видео локально или в облаке. Claude Code CX Codex Cursor +1 1 200 000установок setup-pre-commit Matt Pocock Скилл настраивает pre-commit для JavaScript-репозитория: Husky запускает форматирование, проверку типов и тесты перед коммитом. Claude Code 489 289установок using-git-worktrees Jesse Vincent Готовит изолированное рабочее дерево перед доработкой или выполнением плана. Проверяет текущий репозиторий, выбирает нативные средства платформы либо Git. Claude Code CX Codex 217 153установок finishing-a-development-branch Jesse Vincent Скилл проверяет тесты и помогает выбрать, как завершить работу в ветке: слить её, открыть Pull Request или оставить как есть. Claude Code CX Codex 214 439установок orca-cli stablyai Скилл даёт агенту доступ к worktree, терминалам, артефактам и встроенному браузеру Orca через CLI. Пригодится, когда работа идёт в окружении Orca. Claude Code CX Codex Cursor +1 353 000установок

Вопросы о chaos-engineering

Как установить chaos-engineering в Claude Code?

Выполните команду /plugin install chaos-engineering@claude-code-skills или установите через npx skills add alirezarezvani/claude-skills --skill chaos-engineering -a claude-code.

Что делает скилл chaos-engineering?

Он структурирует подготовку экспериментов по отказоустойчивости, оценивает риски и генерирует план отката. Это предотвращает превращение проверок в неконтролируемые аварии.

Нужны ли внешние библиотеки для скриптов из скилла?

Нет, все три встроенных скрипта используют только стандартную библиотеку Python.

Исходный текст

SKILL.md · MIT
---
name: chaos-engineering
description: Use when planning, running, or learning from chaos engineering experiments. Triggers on "chaos experiment", "fault injection", "gameday", "resilience test", "blast radius", "steady state", "abort criteria", "Chaos Toolkit", "Chaos Mesh", "Litmus", "Gremlin", "AWS FIS", or any deliberate failure-injection question. Ships experiment designer, blast-radius calculator, and postmortem generator (all stdlib Python), 4 references on chaos principles + experiment design + attack taxonomy + tooling landscape, and a /chaos-experiment slash command. Composes with feature-flags-architect (kill switches as abort triggers) and kubernetes-operator (common chaos targets).
context: fork
license: MIT
metadata:
  version: 2.9.0
  author: claude-code-skills
  tags: [chaos-engineering, resilience, fault-injection, gameday, sre, reliability, chaos-toolkit, chaos-mesh, litmus, gremlin, aws-fis]
  compatible_tools: [claude-code, codex-cli, cursor, antigravity, opencode, gemini-cli]
---

# Chaos Engineering

Design experiments that surface real weaknesses in production systems — without becoming outages. Most "chaos engineering" attempts skip steady-state measurement, define no abort criteria, and have no blast-radius bound. This skill enforces the discipline that makes chaos experiments safe and useful.

## When to use

- Planning a chaos experiment (what to break, where, when, how to abort)
- Calculating blast radius before running the experiment
- Reviewing an existing experiment plan for safety
- Choosing a chaos tool (Chaos Toolkit / Chaos Mesh / Litmus / Gremlin / AWS FIS)
- Writing a chaos experiment postmortem
- Running a Game Day exercise

## When NOT to use

- General incident response (use `incident-response`)
- Threat hunting / red-team (use `red-team`, `threat-detection`)
- Performance load testing (different goal — chaos is about failure modes, not capacity)
- Production debugging (chaos discovers weaknesses preemptively, not after-the-fact)

## Core principle: chaos without abort criteria is an outage

The 4 Principles of Chaos Engineering (Netflix, 2016):

1. **Build a hypothesis around steady-state behavior.** Not "what breaks?" but "X holds; will it still hold under fault Y?"
2. **Vary real-world events.** Inject realistic failures: kill nodes, slow networks, lose cache, throttle dependencies.
3. **Run experiments in production.** Staging never has the same failure modes. Start small.
4. **Automate experiments to run continuously.** One-off chaos is a press release; continuous chaos is engineering.

Add a fifth: **Define abort criteria up front.** A chaos experiment with no abort criteria is an outage by another name.

## Quick start

```bash
SKILL=engineering/chaos-engineering/skills/chaos-engineering

# 1. Design an experiment
python "$SKILL/scripts/experiment_designer.py" --target "checkout-svc" --hypothesis "p99 latency stays <500ms" --attack latency --duration-min 15

# 2. Calculate blast radius
python "$SKILL/scripts/blast_radius_calculator.py" --traffic-share 0.05 --user-pop 1000000 --duration-min 15

# 3. Generate postmortem after the experiment
python "$SKILL/scripts/experiment_postmortem.py" --plan experiment.json --result-log results.txt
```

## The 3 Python tools

All stdlib-only. Run with `--help`.

### `experiment_designer.py`

Generates a structured experiment plan from inputs. Enforces the required sections (hypothesis, steady-state metric, blast radius, abort criteria, rollback).

```bash
python scripts/experiment_designer.py \
  --target "checkout-svc" \
  --hypothesis "p99 latency stays <500ms when payment-svc is slow" \
  --attack latency \
  --magnitude "+200ms" \
  --duration-min 15 \
  --blast-radius "5% of US traffic" \
  --abort-if "p99 > 1000ms OR error_rate > baseline + 1pp"
```

Outputs a markdown plan with: hypothesis, steady-state, attack, magnitude, duration, blast radius, abort criteria, rollback procedure, monitoring dashboards, and learning question.

### `blast_radius_calculator.py`

Computes the blast radius of a planned experiment. Given traffic share + user population + duration, calculates expected affected users, expected error budget burn, and a risk score.

```bash
python scripts/blast_radius_calculator.py \
  --traffic-share 0.05 \
  --user-pop 1000000 \
  --duration-min 15 \
  --baseline-availability 0.999 \
  --expected-impact-availability 0.95
```

Outputs:
- Expected affected users
- Error budget consumed (in minutes of error budget)
- Risk score: GREEN / YELLOW / RED
- Recommendation: PROCEED / REDUCE / ABORT

GREEN = <1% error budget; YELLOW = 1-10%; RED = >10%.

### `experiment_postmortem.py`

Produces a structured postmortem from an experiment plan + results. Catches the common postmortem failure modes: no learning recorded, no follow-up actions, blame-laden language.

```bash
python scripts/experiment_postmortem.py --plan experiment.json --result-log results.txt
```

Outputs markdown with: summary, hypothesis (was it confirmed/refuted?), what we learned, what surprised us, follow-up actions with owners, and link to next experiment.

## The 7 attack types (taxonomy)

Different attacks reveal different weaknesses. See `references/attack_taxonomy.md` for full detail.

| Attack | What it tests | Tooling |
|---|---|---|
| **Latency** | Timeouts, retries, circuit breakers | tc, Chaos Mesh `NetworkChaos` |
| **Error** | Error handling, fallback paths | Chaos Mesh `HTTPChaos`, Toxiproxy |
| **Resource** (CPU, memory, disk) | Saturation handling, autoscaling | Chaos Mesh `StressChaos`, stress-ng |
| **Network partition** | Split-brain, consensus, failover | Chaos Mesh `NetworkChaos` partition |
| **Dependency failure** | Graceful degradation, fallback | Service mesh fault injection |
| **Time** | Clock skew, NTP issues | libfaketime, Chaos Mesh `TimeChaos` |
| **Infrastructure** (kill instance) | Auto-recovery, failover | AWS FIS, Chaos Monkey |

Pick the attack that matches the hypothesis. "What happens if X is slow?" → latency. "What happens if X loses network?" → partition.

## Tooling chooser

| Tool | Best for | Pricing | Stack |
|---|---|---|---|
| **Chaos Toolkit** | Lightweight, language-agnostic, JSON experiments | OSS | Any |
| **Chaos Mesh** | Kubernetes-native, rich CRDs, in-cluster | OSS | Kubernetes |
| **Litmus** | Kubernetes, Argo-integrated, large library | OSS + Enterprise | Kubernetes |
| **Gremlin** | Enterprise SaaS, multi-cloud, audit | Paid | Any |
| **AWS FIS** | AWS-native, IAM-integrated, EC2/ECS/EKS | Paid (AWS) | AWS |
| **Custom** | Niche needs, single-cloud, low budget | None | Any |

Decision rules:
- k8s-only stack + OSS → Chaos Mesh or Litmus (Litmus has bigger experiment library)
- Multi-cloud + OSS → Chaos Toolkit
- AWS-heavy + simple needs → AWS FIS
- Enterprise + audit/compliance → Gremlin

See `references/tooling_landscape.md` for trade-offs.

## Workflows

### Workflow 1: Design and run a single experiment

```
1. State a hypothesis: "When [fault], steady-state metric X stays within Y."
2. Identify the steady-state metric — must be measurable BEFORE the experiment.
3. Run blast_radius_calculator.py — confirm GREEN before proceeding.
4. Run experiment_designer.py to produce the plan.
5. Get a peer review of the plan; confirm abort criteria are concrete.
6. Notify the on-call team in #incidents (or whatever channel).
7. Run the experiment with monitoring open.
8. If abort criteria are hit, abort immediately; record what happened.
9. Run experiment_postmortem.py to capture learnings.
10. File follow-up actions; link to next experiment.
```

### Workflow 2: Game Day exercise

```
1. Pick a scenario (e.g., "primary database fails over").
2. Identify all dependent services that should keep working.
3. Build a multi-experiment plan covering each layer.
4. Schedule with stakeholders; on-call coverage required.
5. Run with a facilitator who manages the scenario.
6. Capture observations in a shared doc as they happen.
7. Single combined postmortem covering all observations.
8. Track follow-up actions in a board with owners.
```

### Workflow 3: Continuous chaos (game days → daily)

```
1. Start: weekly Game Day in staging.
2. Move to: weekly Game Day in production with limited blast radius.
3. Mature to: continuous chaos via scheduled experiments (Litmus chaos schedule, Gremlin scenarios).
4. Wire to deployment: every prod deploy triggers a baseline chaos sweep.
5. Track: experiments per week, weaknesses discovered, MTTR trend.
```

## Composition with other skills

This skill explicitly composes with two others in this library:

| Skill | Composition |
|---|---|
| `feature-flags-architect` | Kill switches defined there are the abort triggers here |
| `kubernetes-operator` | Operators are common chaos targets (test reconcile under fault) |
| `incident-response` | Chaos experiments that escalate become incidents |

## Anti-patterns

- **No hypothesis** — "let's break things" is sabotage, not engineering
- **No steady-state metric** — without a baseline, you can't tell if X broke
- **No blast radius bound** — full-prod experiment without limits = outage
- **No abort criteria** — see above; this is mandatory
- **No on-call coverage** — chaos without monitoring is unmonitored production
- **Chaos in staging only** — staging never has prod failure modes
- **Chaos in dev** — useless; dev has different failure modes from prod
- **One-off chaos** — single experiment is a press release; learning requires recurrence
- **Blame-laden postmortem** — record causes, not blame; teams stop running chaos otherwise

## References

- `references/chaos_principles.md` — the 4 principles, history, when to start
- `references/experiment_design.md` — hypothesis structure, steady-state metrics, abort criteria
- `references/attack_taxonomy.md` — 7 attack types with examples and tooling
- `references/tooling_landscape.md` — Chaos Toolkit / Mesh / Litmus / Gremlin / FIS / DIY

## Slash command

`/chaos-experiment` — interactive experiment design wizard that runs all 3 tools.

## Asset templates

- `assets/experiment_template.md` — fill-in plan template
- `assets/postmortem_template.md` — structured postmortem template

## Verifiable success

A team using this skill should achieve:

- 100% of chaos experiments have a written hypothesis, abort criteria, and blast-radius calculation
- Blast radius for any single experiment never exceeds 10% of error budget
- Mean time between chaos experiments <14 days (continuous, not one-off)
- Each experiment produces ≥1 follow-up action that gets shipped
- No chaos experiment escalates to a customer-impacting incident in trailing 90 days

© claude-code-skills · MIT · alirezarezvani/claude-skills

Смотрите также

Спонсоры проекта

Компании, которые помогают держать аналитику открытой