Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makefile changes - Adding multi arch build support for docker image #699

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
12 changes: 12 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ help:
@echo "\tmake push -- pushes the litmus-go multi-arch image"
@echo "\tmake build-amd64 -- builds the litmus-go binary & docker amd64 image"
@echo "\tmake push-amd64 -- pushes the litmus-go amd64 image"
@echo "\tpush-multiarch -- pushes the litmus-go multiarch image"
@echo ""

.PHONY: all
Expand Down Expand Up @@ -90,6 +91,17 @@ push-amd64:
@echo "------------------------------"
@sudo docker push $(DOCKER_REGISTRY)/$(DOCKER_REPO)/$(DOCKER_IMAGE):$(DOCKER_TAG)

.PHONY: push-multiarch
push-multiarch: docker.buildx image-push-multiarch

image-push-arm64:
@echo "------------------------"
@echo "--> Push go-runner image"
@echo "------------------------"
@echo "Pushing $(DOCKER_REPO)/$(DOCKER_IMAGE):$(DOCKER_TAG)"
@docker buildx build . --push --file build/Dockerfile --progress plane --platform linux/arm64,linux/amd64 --no-cache --tag $(DOCKER_REGISTRY)/$(DOCKER_REPO)/$(DOCKER_IMAGE):$(DOCKER_TAG)


.PHONY: trivy-check
trivy-check:

Expand Down