Do not allow to inject version from outside
- Do not allow to inject version from outside
CNG will inject version which we don't want.
Since switching to having the SSoT in the
build/print_workspace_status.sh
script, I missed to remove that
option - which was already the case in the Makefile.
This fix must be backported.
Changelog: fixed
Test Protocol
I've tested this using the Dockerfile
CNG uses (see https://gitlab.com/gitlab-org/build/CNG/-/blob/master/gitlab-kas/Dockerfile):
$ docker buildx build -t kas-cng --build-arg GITLAB_KAS_VERSION=1dd0ece91d724bc090c3e3b88433883b906bd96d --build-arg TARGETPLATFORM=linux/arm64 --build-arg TARGETARCH=arm64 --build-arg CI_API_V4_URL=https://gitlab.com/api/v4 --build-arg FETCH_ARTIFACTS_AT=$GITLAB_TOKEN -f Dockerfile.cng .
$ docker run -it kas-cng --version
kas version v17.0.0-rc1, commit: v17.0.0-rc1, built: 2024-04-30T05:27:15+00:00
This also contributes to Update GITLAB_KAS_VERSION to test deploying fro... (gitlab-org/gitlab!149194 - merged) - because it's actually building KAS from a SHA input.
Edited by Timo Furrer