Skip to content
This repository has been archived by the owner on Sep 2, 2024. It is now read-only.

Commit

Permalink
support all buildkit arch for client and server (#57)
Browse files Browse the repository at this point in the history
- ppc64le
- s390x

Signed-off-by: Jacob Blain Christen <jacob@rancher.com>
  • Loading branch information
dweomer authored May 25, 2021
1 parent 063ee83 commit 5d4c2a0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
14 changes: 8 additions & 6 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,14 @@ steps:
DOCKER_BUILDKIT: "1"
GOLANG: drone.cattle.io/rancher/kim:possible
commands:
- make GOOS=linux GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=arm64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=arm TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=darwin GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=darwin GOARCH=arm64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=windows GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=arm64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=arm TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=s390x TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=linux GOARCH=ppc64le TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=darwin GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=darwin GOARCH=arm64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
- make GOOS=windows GOARCH=amd64 TAG=${DRONE_TAG:-$(git describe --tags --always)} dist
volumes:
- name: docker
path: /var/run/docker.sock
Expand Down
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ ORG ?= rancher
PKG ?= github.com/rancher/kim
TAG ?= $(shell git describe --tags --always)
IMG := $(ORG)/kim:$(subst +,-,$(TAG))
REG ?= docker.io

ifeq ($(GO_BUILDTAGS),)
GO_BUILDTAGS := static_build,netgo,osusergo
Expand All @@ -26,7 +27,7 @@ endif
GO_LDFLAGS ?= -w -extldflags=-static
GO_LDFLAGS += -X $(PKG)/pkg/version.GitCommit=$(shell git rev-parse HEAD)
GO_LDFLAGS += -X $(PKG)/pkg/version.Version=$(TAG)
GO_LDFLAGS += -X $(PKG)/pkg/server.DefaultAgentImage=docker.io/$(ORG)/kim
GO_LDFLAGS += -X $(PKG)/pkg/server.DefaultAgentImage=$(REG)/$(ORG)/kim

GO ?= go
GOLANG ?= golang:1.16-alpine3.12
Expand Down Expand Up @@ -85,7 +86,9 @@ image-manifest-all:
$(IMG) \
$(IMG)-amd64 \
$(IMG)-arm64 \
$(IMG)-arm
$(IMG)-arm \
$(IMG)-ppc64le \
$(IMG)-s390x
DOCKER_CLI_EXPERIMENTAL=enabled $(DOCKER_MANIFEST) annotate \
--arch arm \
--variant v$(GOARM) \
Expand Down

0 comments on commit 5d4c2a0

Please sign in to comment.