Skip to content

Conversation

murugapl
Copy link
Contributor

@murugapl murugapl commented Jun 5, 2025

The previous implementation to display the Mavis version number in the footer of the app used the deploy git ref to create a file with the version number which was baked into the image. With the current deploy strategy, the image is only built during deploys to QA and test, before the version tag is even created. So the version number isn't displayed appropriately in production.

This change uses environment variables to set the version number instead. The MAVIS_APP_VERSION environment variable is now set during infrastructure deployment and passed to the ECS containers. For production deployments, the version format is validated to ensure it follows semantic versioning (v1.2.3 format).

This ensures the correct version number is displayed regardless of when the Docker image was built, as the version is determined at deployment time rather than build time.

@murugapl murugapl requested a review from a team as a code owner June 5, 2025 08:52
Copy link
Contributor

@thomasleese thomasleese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small comments on the naming, but otherwise looks good.

@tvararu tvararu temporarily deployed to mavis-pr-3661 June 5, 2025 08:55 Inactive
@murugapl murugapl force-pushed the fix-version-number-footer branch from f611cc0 to 1033c94 Compare June 5, 2025 09:00
@tvararu tvararu temporarily deployed to mavis-pr-3661 June 5, 2025 09:01 Inactive
@thomasleese thomasleese added this to the v2.2.4 milestone Jun 5, 2025
@thomasleese thomasleese added the bug Something isn't working label Jun 5, 2025
The previous implementation to display the Mavis version
number in the footer of the app used the deploy git ref to
create a file with the version number which was baked into the image.
With the current deploy strategy, the image is only built during
deploys to QA and test, before the version tag is even created. So
the version number isn't displayed appropriately in production.

This change uses environment variables to set the version number
instead. The MAVIS_APP_VERSION environment variable is now set
during infrastructure deployment and passed to the ECS containers.
For production deployments, the version format is validated to
ensure it follows semantic versioning (v1.2.3 format).

This ensures the correct version number is displayed regardless
of when the Docker image was built, as the version is determined
at deployment time rather than build time.
@murugapl murugapl force-pushed the fix-version-number-footer branch from 1033c94 to 2cbe18e Compare June 5, 2025 09:08
@tvararu tvararu temporarily deployed to mavis-pr-3661 June 5, 2025 09:09 Inactive
Copy link

sonarqubecloud bot commented Jun 5, 2025

@murugapl murugapl merged commit 744c2d5 into main Jun 5, 2025
35 of 37 checks passed
@murugapl murugapl deleted the fix-version-number-footer branch June 5, 2025 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants