Skip to content

Promotions

Move solution versions through your environment pipeline.

Promotion deploys a solution version from one environment to the next in your pipeline:

Promotion follows sort order:

EnvironmentSort OrderPromotes To
Development0Staging
Staging10Production
Production20(End of pipeline)
┌─────────────────────────────────────────────────────────────┐
│ customer-portal - Environment State │
├─────────────────────────────────────────────────────────────┤
│ │
│ ┌────────────┬─────────┬────────────────┬───────────────┐ │
│ │Environment │ Version │ Last Deployed │ Action │ │
│ ├────────────┼─────────┼────────────────┼───────────────┤ │
│ │Development │ 1.4.0 │ Today │ [Promote →] │ │
│ │Staging │ 1.3.0 │ 3 days ago │ [Promote →] │ │
│ │Production │ 1.3.0 │ 1 week ago │ - │ │
│ └────────────┴─────────┴────────────────┴───────────────┘ │
│ │
└─────────────────────────────────────────────────────────────┘
┌─────────────────────────────────────────────────────────────┐
│ Promote Solution │
├─────────────────────────────────────────────────────────────┤
│ │
│ Solution: customer-portal │
│ Version: 1.4.0 │
│ │
│ From: Development │
│ To: Staging │
│ │
│ Targets in Staging: 4 │
│ web-stg-01, web-stg-02, api-stg-01, db-stg-01 │
│ │
│ ───────────────────────────────────────────────────────── │
│ │
│ [Cancel] [Promote] │
│ │
└─────────────────────────────────────────────────────────────┘

Promotions are created through the REST API. There is no mantisctl subcommand for promotions. Send a POST to /api/v1/promotions with the solution and the source and target environment IDs:

Terminal window
# Promote to the next environment
curl -X POST https://mantis.example.com/api/v1/promotions \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"solution_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"source_environment_id": "11111111-1111-1111-1111-111111111111",
"target_environment_id": "22222222-2222-2222-2222-222222222222"
}'
# With execution options (rolling waves)
curl -X POST https://mantis.example.com/api/v1/promotions \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"solution_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"source_environment_id": "22222222-2222-2222-2222-222222222222",
"target_environment_id": "33333333-3333-3333-3333-333333333333",
"target_mode": { "rolling": { "batch_size": 3 } }
}'

The promotions:create permission is required. Use POST /api/v1/promotions/preview to preview the resulting deployment before creating it.

Before promotion can occur:

The version must be successfully deployed to the source environment.

The target environment needs at least one online target.

Soak time is a minimum wait period before promotion:

┌─────────────────────────────────────────────────────────────┐
│ Promote Blocked: Soak Time │
├─────────────────────────────────────────────────────────────┤
│ │
│ Version 1.4.0 cannot be promoted yet. │
│ │
│ Deployed to Development: 2 hours ago │
│ Required soak time: 24 hours │
│ Time remaining: 22 hours │
│ │
│ ┌───────────────────────────────────────────────────────┐ │
│ │ Soak time ensures versions are stable before │ │
│ │ promotion. Contact admin for emergency override. │ │
│ └───────────────────────────────────────────────────────┘ │
│ │
└─────────────────────────────────────────────────────────────┘
EnvironmentSoak TimePurpose
DevelopmentNoneRapid iteration
Staging1-4 hoursBasic validation
Production24-48 hoursExtended testing

Some promotions require approval:

┌─────────────────────────────────────────────────────────────┐
│ Approval Required │
├─────────────────────────────────────────────────────────────┤
│ │
│ Promoting to Production requires approval. │
│ │
│ Required approvers: │
│ ○ Release Manager │
│ ○ QA Lead │
│ │
│ Current approvals: │
│ (none) │
│ │
│ [Request Approval] │
│ │
└─────────────────────────────────────────────────────────────┘

In emergencies, skip environments:

┌─────────────────────────────────────────────────────────────┐
│ Skip Promotion │
├─────────────────────────────────────────────────────────────┤
│ │
│ ⚠ Warning: You are skipping environments │
│ │
│ Solution: customer-portal │
│ Version: 1.4.1 (hotfix) │
│ │
│ From: Development │
│ Skipping: Staging │
│ To: Production │
│ │
│ This is an emergency promotion. Are you sure? │
│ │
│ [Cancel] [Skip and Promote] │
│ │
└─────────────────────────────────────────────────────────────┘

Each promotion is recorded as a deployment of type promotion in the deployment history. The deployments list endpoint has no deployment_type filter, so there is no single call that returns only promotion deployments. To inspect promotions:

Terminal window
# Promotions awaiting approval
curl "https://mantis.example.com/api/v1/promotions/pending" \
-H "Authorization: Bearer $TOKEN"
# A specific promotion by id
curl "https://mantis.example.com/api/v1/promotions/<promotion-id>" \
-H "Authorization: Bearer $TOKEN"

If promotion causes issues:

┌─────────────────────────────────────────────────────────────┐
│ Rollback Solution │
├─────────────────────────────────────────────────────────────┤
│ │
│ Solution: customer-portal │
│ Environment: Production │
│ Current: v1.4.0 │
│ │
│ Rollback to: │
│ ● v1.3.0 - Previous version (recommended) │
│ ○ v1.2.0 - 2 weeks ago │
│ ○ v1.1.0 - 1 month ago │
│ │
│ [Cancel] [Rollback] │
│ │
└─────────────────────────────────────────────────────────────┘
FactorConsider
Database changesMay need manual migration rollback
API compatibilityClients may need updates
Data formatNew data may be incompatible
External dependenciesThird-party integrations

Visual promotion overview:

┌─────────────────────────────────────────────────────────────┐
│ Promotion Dashboard │
├─────────────────────────────────────────────────────────────┤
│ │
│ customer-portal: │
│ ┌────────────┐ ┌────────────┐ ┌────────────┐ │
│ │Development │ -> │ Staging │ -> │ Production │ │
│ │ v1.4.0 │ │ v1.3.0 │ │ v1.3.0 │ │
│ │ [Ready] │ │ [Ready] │ │ [Current] │ │
│ └────────────┘ └────────────┘ └────────────┘ │
│ ↓ ↓ │
│ [Promote →] [Promote →] │
│ │
│ auth-service: │
│ ┌────────────┐ ┌────────────┐ ┌────────────┐ │
│ │Development │ -> │ Staging │ -> │ Production │ │
│ │ v2.2.0 │ │ v2.1.0 │ │ v2.1.0 │ │
│ │ [Ready] │ │ [Soak: 4h] │ │ [Current] │ │
│ └────────────┘ └────────────┘ └────────────┘ │
│ ↓ │
│ [Promote →] │
│ │
└─────────────────────────────────────────────────────────────┘

Ensure adequate testing at each stage:

EnvironmentMinimum Testing
DevelopmentUnit tests, smoke tests
StagingIntegration tests, UAT
ProductionMonitoring, rollback ready

Configure appropriate soak times:

  • Too short: Issues reach production
  • Too long: Delays releases

Consider automated promotions for:

  • Development → Staging (after CI passes)
  • With manual gates for Production

Record promotion context:

Promotion: customer-portal v1.4.0 to Production
Date: 2024-01-20
Approvers: Release Manager, QA Lead
Testing: 3 days in staging
Changes: New checkout flow, payment fixes
Rollback: v1.3.0 verified working

Watch for issues immediately after promotion:

  • Error rates
  • Response times
  • User complaints
  • System resources

Cause: Version hasn’t been in environment long enough

Solution: Wait for soak time, or request emergency override

Cause: Target environment requires approval

Solution: Request approval from required approvers

Cause: Deployment to target environment failed

Solution: Check logs, fix issues, retry promotion

Cause: Interrupted promotion or partial failure

Solution: Verify state, redeploy if needed