# CI CD

> Use when: design or improve a CI/CD pipeline for fast, reliable, automated build-test-deploy.

- Skill: `kimtth/ci-cd` (Agent Skill)
- Install (CLI): `npx skillmds@latest add kimtth/ci-cd`
- Raw SKILL.md: https://api.skillmd.com/api/skills/kimtth/ci-cd/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: DevOps & Infra
- Author: kimtth (https://skillmd.com/u/kimtth)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/kimtth/ci-cd

---


Goal: every change is built, tested, and deployable automatically.

Use for:
- setting up or improving build/test/deploy automation
- making pipelines fast, reliable, and trustworthy
- adding safe, repeatable deployments

Workflow:
1. Build and test on every push and pull request.
2. Keep the pipeline fast: cache deps, parallelize jobs.
3. Fail fast and surface clear, actionable errors.
4. Gate merges on green checks and required reviews.
5. Deploy from a known-good artifact, not a fresh build.
6. Make rollback a one-step, practiced operation.

Pipeline stages:
- lint and type-check
- unit and integration tests
- build a versioned artifact once
- deploy with health checks and easy rollback

Rules:
- a red pipeline blocks merge; keep main always green
- build the artifact once and promote it across stages
- make pipelines deterministic; eliminate flaky tests
- ensure rollback is fast and rehearsed

