-
Task
-
Resolution: Unresolved
-
Major
-
None
-
None
-
None
-
None
-
5
-
False
-
-
False
-
subs-swatch-lightning
-
-
Context
The Konflux IntegrationTestScenario for swatch-contracts-bonfire-tekton is currently failing to successfully deploy because it cannot properly handle the swatch-database dependency. The bonfire-tekton integration needs to be enhanced to override the MIGRATION_IMAGE tag in addition to the IMAGE tag that it already handles.
Current State
- bonfire-tekton (https://github.com/RedHatInsights/bonfire-tekton) successfully overrides IMAGE tags
- MIGRATION_IMAGE tags are not being overridden, causing deployment failures for swatch components with database dependencies
- swatch-contracts requires swatch-database component with proper migration image handling
Technical Details
The MIGRATION_IMAGE tag needs to be overridden similar to how the IMAGE tag is currently handled in the bonfire-tekton repository. This is required for swatch components that have database migration dependencies.
Update from jcarvaja@redhat.com
There were the following issues in the existing integration test definition:
- we can't set "--remove-dependencies swatch-contracts", because the swatch-database won't be deployed and hence clowder will fail to find this dependency (even when we deploy it using the COMPONENTS param and swatch-database is up and ready).
- we were missing some components like artemis.
Apart from the above issues that have been already fixed:
- since we can't use --remote-dependencies, we need to deploy swatch-tally because at the moment, swatch-contracts depends on swatch-tally. We'll be fixed by
SWATCH-3895.
And then, the final remaining issues are:
- Konflux is running the integration test before verifying that all the components have the same IMAGE_TAG. So, we can't use the same IMAGE_TAG for swatch-contracts and swatch-database.
- Related to above, we can't workaround the Konflux issue by adding an additional parameter MIGRATION_IMAGE_TAG because OpenShift does not support inheriting this parameter with a fallback of the "IMAGE_TAG" property, which is the only one that is used when promoting the services to stage and production.
Therefore, the only solution I see is to get rid of the init-container that run the migrations which is giving more problems than solutions. This is up to discussion. Reported by SWATCH-4032.
Acceptance Criteria
- swatch-contracts-bonfire-tekton IntegrationTestScenario deploys successfully
- Database migrations run correctly in ephemeral environments
- Solution follows the same pattern as existing IMAGE tag override mechanism
- is blocked by
-
SWATCH-4032 Move contracts migration scripts from swatch-database-migrations to swatch-contracts
-
- In Progress
-
-
SWATCH-3895 swatch-contracts fails to start in ephemeral if swatch-tally isn't deployed
-
- Release Pending
-
- is depended on by
-
SWATCH-3789 Add tally snapshot consumer in swatch-contracts to set the capacity
-
- In Progress
-
- mentioned on