Build gitlab-kas using bazel
Problem to solve
Currently, KAS in Omnibus is built using make kas
, which relies on the system go version for build (as opposed to the bazel build, which brings the "correct" go version). This can lead to problems like #6893 (closed).
Proposal
- Use bazelisk to bootstrap bazel in the build environment, like we do in CNG.
- Build and install KAS using bazel, for example with
bazel run //cmd/kas:extract_kas -- $TARGET_DIR
More information
If memory servers correctly, the make kas
target was made specifically for Omnibus to cater to an old CentOS version where bazel would not work for some reason. So the first thing to check before spending to much time on this is whether this is still a blocker.