database-migrations

Plan and implement reversible database migrations across PostgreSQL, MySQL, and ORMs.

1|1|Updated Mar 31, 2026
One-click install
npx skills add https://github.com/zardusai-cyber/zardus_setup --skill database-migrations-zardusai-cyber
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-migrations
Source: https://github.com/zardusai-cyber/zardus_setup/tree/main/ecc/skills/database-migrations
Command: npx skills add https://github.com/zardusai-cyber/zardus_setup --skill database-migrations-zardusai-cyber

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Database migrations are risky and error-prone when changing production schemas, leading to downtime or data loss without proper practices.

Core Features & Use Cases

  • Safe UP/DOWN migrations for schema changes across PostgreSQL, MySQL, and ORMs
  • Separation of schema and data migrations with identifiable backfills
  • Zero-downtime deployment readiness with expand-contract patterns and rollback planning

Quick Start

Plan and implement a zero-downtime migration for a sample schema change in a test environment

Frequently Asked Questions about database-migrations

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I perform zero-downtime database migrations in a multi-ORM environment?

Zero-downtime database migrations in multi-ORM environments require separating schema and data changes, using expand-contract patterns, and planning robust rollbacks to prevent production downtime. This approach applies across PostgreSQL, MySQL, Prisma, and Drizzle.

What is the best way to plan reversible database schema changes for production?

Reversible database schema changes for production require explicit UP/DOWN migrations or irreversible declarations, non-blocking indexing, and identifiable data backfills to ensure safe rollback planning. Separating schema and data migrations reduces risk during deployment.

Does this approach support both Prisma and Drizzle for rollback planning?

Yes, this approach supports rollback planning across common ORMs including Prisma and Drizzle, as well as PostgreSQL and MySQL databases. It enforces safe UP/DOWN migrations and explicit irreversible migrations to manage schema changes safely.

How do I separate schema migrations from data backfills safely?

To separate schema migrations from data backfills safely, enforce distinct migration paths for structural changes versus data transformations, using non-blocking indexing and identifiable backfills to maintain zero-downtime deployment readiness.

When should I use expand-contract patterns for database migrations?

Expand-contract patterns for database migrations should be used when performing zero-downtime deployments that require non-blocking indexing and robust rollback planning. This pattern separates schema expansions from subsequent contract changes to avoid production data loss.

How do I handle irreversible database migrations safely?

Irreversible database migrations are handled safely by explicitly declaring them as irreversible, separating schema and data changes, and ensuring robust rollback planning exists for all surrounding reversible UP/DOWN migrations to minimize production risk.