Skip to content

Commit 0c73fa5

Browse files
committed
build: set --load as BUILD_ARGS default
Otherwise overwriting it with e.g. `--push` is not possible as the combination with `--load` results in an error. Signed-off-by: Hidde Beydals <hello@hidde.co>
1 parent bfb283c commit 0c73fa5

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.github/workflows/e2e.yaml

+2-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ jobs:
7373
make docker-build IMG=test/helm-controller:latest \
7474
BUILD_PLATFORMS=linux/amd64 \
7575
BUILD_ARGS="--cache-from=type=local,src=/tmp/.buildx-cache \
76-
--cache-to=type=local,dest=/tmp/.buildx-cache-new,mode=max"
76+
--cache-to=type=local,dest=/tmp/.buildx-cache-new,mode=max \
77+
--load"
7778
- # Temp fix
7879
# https://github.com/docker/build-push-action/issues/252
7980
# https://github.com/moby/buildkit/issues/1896

Makefile

+1-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ GOBIN=$(shell go env GOBIN)
1111
endif
1212

1313
# Allows for defining additional Docker buildx arguments, e.g. '--push'.
14-
BUILD_ARGS ?=
14+
BUILD_ARGS ?= --load
1515
# Architectures to build images for.
1616
BUILD_PLATFORMS ?= linux/amd64
1717

@@ -94,7 +94,6 @@ docker-build:
9494
docker buildx build \
9595
--platform=$(BUILD_PLATFORMS) \
9696
-t ${IMG} \
97-
--load \
9897
${BUILD_ARGS} .
9998

10099
# Push the docker image

0 commit comments

Comments
 (0)