/gaia-rollback-plan

user-facing
Category:
Deployment
Lifecycle phase:
5 -- Deployment

What it does

/gaia-rollback-plan generates a rollback plan for a release, covering automated and manual trigger criteria, a step-by-step rollback procedure, a data rollback strategy, a communication plan, and post-rollback verification steps. The plan is designed to be executable during an incident without additional approvals.

When to use it

  • You are preparing for a production deployment and need a documented rollback procedure.
  • An incident occurred and you need to reference the rollback plan.

Prerequisites

  • Architecture document should exist for deployment-relevant context. The command reads infrastructure topology and deployment strategy from it.

How to invoke

/gaia-rollback-plan

What it does step by step

  1. Validate project config Reads the architecture and project configuration for deployment context.
  2. Define trigger criteria Establishes automated triggers (error rate, health check failures, critical alerts) and manual triggers (user reports, data integrity, security).
  3. Define rollback procedure Creates step-by-step execution instructions with expected duration for each method (blue-green, redeploy, feature flag).
  4. Define data rollback strategy Documents database migration reversal, data fix procedures, non-reversible data handling, and cache invalidation.
  5. Define communication plan Sets notification timelines: immediate, short-term, post-rollback, and post-mortem.
  6. Generate artifact Writes the rollback plan to .gaia/artifacts/implementation-artifacts/rollback-plan-{version}.md.

Inputs

InputSourceDescription
Architecture document.gaia/artifacts/planning-artifacts/architecture.mdProvides deployment topology and rollback mechanisms.
Project configuration.gaia/config/project-config.yamlCI/CD and environment settings.

Outputs

OutputLocationDescription
Rollback plan.gaia/artifacts/implementation-artifacts/rollback-plan-{version}.mdComplete rollback plan with trigger criteria, procedures, data strategy, and communication plan.

Example session

> /gaia-rollback-plan

Loading architecture and config...

Generating rollback plan...
  Trigger criteria: 4 automated, 4 manual
  Rollback procedure: blue-green (< 1 min), redeploy (5-10 min)
  Data rollback strategy: migration reversal documented
  Communication plan: 4-phase timeline

Written to .gaia/artifacts/implementation-artifacts/rollback-plan-1.3.0.md

What to run next

Troubleshooting

No prior deployment state

If no previous deployment exists to roll back to, the plan is generated with a warning noting the gap.

Project config is malformed

Fix the configuration before retrying. The command needs valid CI/CD settings to generate environment-specific procedures.