MATIH Platform is in active MVP development. Documentation reflects current implementation status.
7. Tenant Lifecycle
Helm Releases
Release Rollbacks

Release Rollbacks

Rollback operations restore a Helm release to a previous revision. This is used to recover from failed upgrades or to revert configuration changes. The platform supports targeted rollbacks to a specific revision and automated rollback to the last known successful state.


Rollback to Specific Revision

POST /api/v1/helm/releases/:releaseId/rollback
{
  "targetRevision": 3
}

The targetRevision must be a valid revision number from the release history. The rollback creates a new revision with the configuration from the target revision.


Rollback to Last Successful

POST /api/v1/helm/releases/:releaseId/rollback/last-successful

Automatically determines the most recent revision with DEPLOYED status and rolls back to it. This is useful when the current revision number of the last good state is unknown.


Rollback Behavior

AspectBehavior
New revisionRollback creates a new revision (does not rewrite history)
ValuesRestores the exact values from the target revision
Chart versionRestores the chart version from the target revision
Status flowDEPLOYED to PENDING_ROLLBACK to DEPLOYED or FAILED

Revision History After Rollback

Rollback does not delete revisions. Given an initial install (rev 1), upgrade (rev 2), and rollback to rev 1:

RevisionOperationChart Version
1Install1.0.0
2Upgrade1.1.0
3Rollback to 11.0.0

The history shows three revisions, with revision 3 containing the same configuration as revision 1.


Atomic Installs

When a release is installed with atomic: true, a failed installation is automatically rolled back by Helm. This provides a built-in safety net for new deployments.


Recovery from Failed Rollback

If a rollback itself fails, the release enters FAILED status. Recovery options include:

  1. Retry the rollback to a different revision
  2. Perform a fresh upgrade with known-good configuration
  3. Uninstall and reinstall the release

Check the release history to identify which revisions are in DEPLOYED status for a safe rollback target.