Infra module upgrades: Only allow +1 major per apply
Summary
This feature provides guard rails around infrastructure upgrades.
Intended Outcome
- Users are prevented from applying infrastructure changes that could cause irreversible damage to infrastructure.
- Users are prevented from applying infrastructure changes that result in corrupted state files.
How will it work?
When a user runs "Update" on an existing app, datastore, domain, or block that is marked to use "latest" version of the infra module, Nullstone will only allow new versions of the module that are at most +1 major version. Once successfully applied, the engine will allow an upgrade with another +1 to major.
Example
- User has a datastore
postgres0usingaws-rds-postgresusinglatestand recently applied withv0.9.1 -
aws-rds-postgreshasv0.10.0andv0.11.0available - When clicking update, Nullstone will select and only allow
v0.10.0 - After completing
v0.10.0successfully, user will be able to select and applyv0.11.0
Caveats
Nullstone is optimized for a "roll-forward" provisioning strategy. If there is a bug or change that needs to be applied, then a new version is introduced to remediate.
However, there are cases when a user's infrastructure is in a bad state and a version rollback is necessary. This feature would also enforce a max of -1 major version rollback as well.