actions-docker/Makefile
2024-08-18 18:04:05 +02:00

18 lines
813 B
Makefile

PLATFORMS=linux/amd64
help:
@echo "make help Displays help"
@echo " build Builds the image"
@echo " upload Builds and uploads the image"
@echo " prune-cache Prunes the entire build cache"
build:
docker buildx rm actions-docker || true
docker buildx create --name actions-docker --bootstrap --use
docker buildx build --platform ${PLATFORMS} -t git.staropensource.de/staropensource/actions-docker:latest -f Dockerfile .
docker buildx build --platform ${PLATFORMS} -t git.staropensource.de/staropensource/actions-docker:java -f Dockerfile.java .
docker buildx rm actions-docker
upload: build
docker push git.staropensource.de/staropensource/actions-docker:latest
docker push git.staropensource.de/staropensource/actions-docker:java
prune-cache:
docker buildx prune -af