Skip to content

Commit

Permalink
Makefile: use buildx
Browse files Browse the repository at this point in the history
  • Loading branch information
f3l1x committed Sep 17, 2024
1 parent 5f19c00 commit 7319d6f
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,33 @@

ADMINER_VERSION=4.8.1
DOCKER_IMAGE=dockette/adminer
DOCKER_PLATFORMS=linux/amd64

build-all: build-full build-dg build-editor build-mongo build-mysql build-postgres build-oracle-11 build-oracle-12

build-full:
docker build -t ${DOCKER_IMAGE}:full ./adminer-full
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:full ./adminer-full

build-dg:
docker build -t ${DOCKER_IMAGE}:dg ./adminer-dg
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:dg ./adminer-dg

build-editor:
docker build -t ${DOCKER_IMAGE}:editor ./adminer-editor
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:editor ./adminer-editor

build-mongo:
docker build -t ${DOCKER_IMAGE}:mongo ./adminer-mongo
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:mongo ./adminer-mongo

build-mysql:
docker build -t ${DOCKER_IMAGE}:mysql ./adminer-mysql
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:mysql ./adminer-mysql

build-oracle-11:
docker build -t ${DOCKER_IMAGE}:oracle-11 ./adminer-oracle-11
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:oracle-11 ./adminer-oracle-11

build-oracle-12:
docker build -t ${DOCKER_IMAGE}:oracle-12 ./adminer-oracle-12
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:oracle-12 ./adminer-oracle-12

build-postgres:
docker build -t ${DOCKER_IMAGE}:postgres ./adminer-postgres
docker buildx build --platform ${DOCKER_PLATFORMS} -t ${DOCKER_IMAGE}:postgres ./adminer-postgres

update-versions:
find . -type f -name Dockerfile -exec sed -i '' 's/ENV ADMINER_VERSION=.*/ENV ADMINER_VERSION=${ADMINER_VERSION}/g' {} +
Expand Down

0 comments on commit 7319d6f

Please sign in to comment.