Merge pull request #130473 from dims/ensure-we-switch-to-k8s-root-directory-for-dockerized-builds-during-e2e-node-ci-job

Ensure we switch to k8s root directory for dockerized builds during e2e-node ci job
This commit is contained in:
Kubernetes Prow Robot 2025-02-27 10:32:30 -08:00 committed by GitHub
commit 807d22f052
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -77,6 +77,8 @@ func BuildTargets(cgo bool) error {
klog.Infof("Building dockerized k8s binaries targets %s for architecture %s", targets, GetTargetBuildArch())
// Multi-architecture build is only supported in dockerized build
cmd = exec.Command(filepath.Join(k8sRoot, "build/run.sh"), "make", fmt.Sprintf("WHAT=%s", what), fmt.Sprintf("KUBE_BUILD_PLATFORMS=%s", GetTargetBuildArch()))
// Ensure we run this command in k8s root directory for dockerized build
cmd.Dir = k8sRoot
}
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr