Skip to content

Commit 0ff7bb3

Browse files
dcaravelvladbologa
andauthored
fix apple silicon local scanner build (#1038)
Co-authored-by: Vlad Bologa <vbologa@redhat.com>
1 parent d5eb96c commit 0ff7bb3

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ BUILD_IMAGE := $(DEFAULT_IMAGE_REGISTRY)/apollo-ci:$(BUILD_IMAGE_VERSION)
3434

3535
ifeq ($(shell uname -ms),Darwin arm64)
3636
# TODO(ROX-12064) build these images in the CI pipeline
37-
BUILD_IMAGE = quay.io/rhacs-eng/sandbox:apollo-ci-scanner-build-0.3.44-arm64
37+
# Uncomment the line below to enable native arm64 builder images
38+
# BUILD_IMAGE = quay.io/rhacs-eng/sandbox:apollo-ci-stackrox-build-0.3.49-arm64
3839
ARCH := aarch64
3940
GOARCH := arm64
4041
else
@@ -44,7 +45,7 @@ endif
4445

4546
LOCAL_VOLUME_ARGS := -v$(CURDIR):/src:delegated -v $(GOPATH):/go:delegated
4647
GOPATH_WD_OVERRIDES := -w /src -e GOPATH=/go
47-
IMAGE_BUILD_FLAGS := -e CGO_ENABLED=0,GOOS=linux,GOARCH=${GOARCH}
48+
IMAGE_BUILD_FLAGS := -e CGO_ENABLED=0 -e GOOS=linux -e GOARCH=${GOARCH}
4849
BUILD_FLAGS := CGO_ENABLED=0 GOOS=linux GOARCH=${GOARCH}
4950
BUILD_CMD := go build -trimpath -ldflags="-X github.com/stackrox/scanner/pkg/version.Version=$(TAG)" -o image/scanner/bin/scanner ./cmd/clair
5051

0 commit comments

Comments
 (0)