From 2ad516c23c867276f985b496755cc517b103d2fd Mon Sep 17 00:00:00 2001 From: vsoch Date: Sun, 11 Aug 2024 17:14:46 -0600 Subject: [PATCH] fix: upstream changes for build and charts Problem: the current fluence build is broken. Solution: the issue is two fold, and unfortunately depends on the docker version. For newer docker that requires --load, that argument would be needed in the build script, and we will need to add it (and then add the script to our assets) if a newer version is used in the CI. The other breaking change was changing the location of the kube- scheduler binary in the controller image. Both of these should now be fixed, and I will update the PR further pending results in CI. Signed-off-by: vsoch --- .github/test.sh | 0 Makefile | 7 ++++--- examples/kind-config.yaml | 2 -- .../charts/as-a-second-scheduler/templates/deployment.yaml | 2 +- 4 files changed, 5 insertions(+), 6 deletions(-) mode change 100644 => 100755 .github/test.sh diff --git a/.github/test.sh b/.github/test.sh old mode 100644 new mode 100755 diff --git a/Makefile b/Makefile index d48348e..33a5ab1 100644 --- a/Makefile +++ b/Makefile @@ -16,9 +16,9 @@ PLATFORMS ?= linux/amd64 BUILDER ?= docker # We match this to the fluence build (see src/build/scheduler/Dockerfile) -GO_VERSION ?= "1.21.9" -GO_BASE_IMAGE?=golang:$(GO_VERSION) -DISTROLESS_BASE_IMAGE?=gcr.io/distroless/static:nonroot +GO_VERSION ?= 1.21.9 +GO_BASE_IMAGE ?= golang:${GO_VERSION} +DISTROLESS_BASE_IMAGE ?= gcr.io/distroless/static:nonroot .PHONY: all build build-sidecar clone update push push-sidecar push-controller @@ -55,6 +55,7 @@ prepare: clone cp sig-scheduler-plugins/cmd/controller/app/server.go $(CLONE_UPSTREAM)/cmd/controller/app/server.go build: prepare + echo ${GO_BASE_IMAGE} BUILDER=${BUILDER} PLATFORMS=${PLATFORMS} REGISTRY=${REGISTRY} IMAGE=${SCHEDULER_IMAGE} \ CONTROLLER_IMAGE=${CONTROLLER_IMAGE} RELEASE_VERSION=${RELEASE_VERSION} \ GO_BASE_IMAGE=${GO_BASE_IMAGE} DISTROLESS_BASE_IMAGE=${DISTROLESS_BASE_IMAGE} \ diff --git a/examples/kind-config.yaml b/examples/kind-config.yaml index 2971483..788aedf 100644 --- a/examples/kind-config.yaml +++ b/examples/kind-config.yaml @@ -21,6 +21,4 @@ nodes: - role: worker - role: worker - role: worker -- role: worker -- role: worker - role: worker \ No newline at end of file diff --git a/sig-scheduler-plugins/manifests/install/charts/as-a-second-scheduler/templates/deployment.yaml b/sig-scheduler-plugins/manifests/install/charts/as-a-second-scheduler/templates/deployment.yaml index 289a0e5..7880c17 100644 --- a/sig-scheduler-plugins/manifests/install/charts/as-a-second-scheduler/templates/deployment.yaml +++ b/sig-scheduler-plugins/manifests/install/charts/as-a-second-scheduler/templates/deployment.yaml @@ -67,7 +67,7 @@ spec: - containerPort: {{ .Values.scheduler.port }} hostPort: {{ .Values.scheduler.port }}{{ end }} - command: - - /bin/kube-scheduler + - /kube-scheduler - --config=/etc/kubernetes/scheduler-config.yaml - -v={{ .Values.scheduler.loggingLevel }} image: {{ .Values.scheduler.image }}