File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
cluster/addons/addon-manager Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,8 @@ KUBECTL_VERSION?=v1.13.2
20
20
21
21
BASEIMAGE =k8s.gcr.io/debian-base-$(ARCH ) :0.4.0
22
22
23
+ SUDO =$(if $(filter 0,$(shell id -u) ) ,,sudo)
24
+
23
25
.PHONY : build push
24
26
25
27
all : build
@@ -29,6 +31,12 @@ build:
29
31
curl -sSL --retry 5 https://dl.k8s.io/release/$(KUBECTL_VERSION ) /bin/linux/$(ARCH ) /kubectl > $(TEMP_DIR ) /kubectl
30
32
chmod +x $(TEMP_DIR ) /kubectl
31
33
cd $(TEMP_DIR ) && sed -i.back " s|BASEIMAGE|$( BASEIMAGE) |g" Dockerfile
34
+
35
+ ifneq ($(ARCH ) ,amd64)
36
+ # Register /usr/bin/qemu-ARCH-static as the handler for non-x86 binaries in the kernel
37
+ $(SUDO) ../../../third_party/multiarch/qemu-user-static/register/register.sh --reset
38
+ endif
39
+
32
40
docker build --pull -t $(IMAGE)-$(ARCH):$(VERSION) $(TEMP_DIR)
33
41
34
42
push : build
You can’t perform that action at this time.
0 commit comments