Stop unsetting the golang buildid

Golang fixed the issue with the non-reproducible buildid already in
v1.15.3:

c5f6920212
a3e965ce8a

This means we can now use the internal buildid instead of the unset one.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
This commit is contained in:
Sascha Grunert 2021-04-23 10:21:00 +02:00
parent 727ecc6353
commit 746ec78ebf
No known key found for this signature in database
GPG Key ID: 09D97D153EF94D93

View File

@ -794,7 +794,7 @@ kube::golang::build_binaries() {
# Disable SC2153 for this, as it will throw a warning that the local
# variable goldflags will exist, and it suggest changing it to this.
# shellcheck disable=SC2153
goldflags="${GOLDFLAGS=-s -w -buildid=} $(kube::version::ldflags)"
goldflags="${GOLDFLAGS=-s -w} $(kube::version::ldflags)"
goasmflags="-trimpath=${KUBE_ROOT}"
gogcflags="${GOGCFLAGS:-} -trimpath=${KUBE_ROOT}"