From 3698434d6bb6df126e534d91d32ac461b629343c Mon Sep 17 00:00:00 2001 From: Sascha Grunert Date: Thu, 1 Dec 2022 11:20:21 +0100 Subject: [PATCH] Link `kube-aggregator` binary statically The kube-aggregator itself only depends on the following runtime libraries when linking dynamically: ``` > ldd _output/bin/kube-aggregator linux-vdso.so.1 (0x00007fff1616f000) libpthread.so.0 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/libpthread.so.0 (0x00007fad9339a000) libc.so.6 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/libc.so.6 (0x00007fad93000000) /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/ld-linux-x86-64.so.2 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib64/ld-linux-x86-64.so.2 (0x00007fad933a1000) ``` We now move the kube-aggregator to become a static binary as well to achieve maximum portability. Signed-off-by: Sascha Grunert --- hack/lib/golang.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/hack/lib/golang.sh b/hack/lib/golang.sh index fb97ee76783..b7bf2db2c96 100755 --- a/hack/lib/golang.sh +++ b/hack/lib/golang.sh @@ -325,6 +325,7 @@ readonly KUBE_ALL_TARGETS=( readonly KUBE_ALL_BINARIES=("${KUBE_ALL_TARGETS[@]##*/}") readonly KUBE_STATIC_LIBRARIES=( + kube-aggregator kube-apiserver kube-controller-manager kube-scheduler