Skip to content

Conversation

@sandhose
Copy link
Member

This fixes the reporting of the version in pre-built binaries and in the docker image.

This uses a feature from vergen which allows us to override any variables with environment variables.
It also tweaks the Docker bake file to introduce a VERGEN_GIT_DESCRIBE variable, which is passed down as build arg to the Dockerfile, which is then passed down as environment variable.
This way, we can also override the version in the docker image by setting the VERGEN_GIT_DESCRIBE environment variable.

Another pass-by change is to set SOURCE_DATE_EPOCH to the timestamp of the last commit, so that Docker considers the build as being reproducible. Not sure if we get a 1:1 binary match from two independant builds, but it's a good thing to have.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 27, 2025

Deploying matrix-authentication-service-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 1016357
Status: ✅  Deploy successful!
Preview URL: https://2e393cbc.matrix-authentication-service-docs.pages.dev
Branch Preview URL: https://quenting-fix-version-reporti.matrix-authentication-service-docs.pages.dev

View logs

@sandhose sandhose requested a review from reivilibre January 27, 2025 09:43
@sandhose sandhose merged commit 060d8ad into release/v0.13 Jan 27, 2025
22 checks passed
@sandhose sandhose deleted the quenting/fix-version-reporting branch January 27, 2025 12:01
@sandhose sandhose added A-Container Related to the Docker container T-Defect Something isn't working labels Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Container Related to the Docker container T-Defect Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants