From 3a955a45dcc45e788f08315835b87d124fb3a976 Mon Sep 17 00:00:00 2001 From: "J.P. Krauss" Date: Thu, 14 Jul 2022 15:53:28 -0700 Subject: [PATCH] Setup multiplatform Docker builds --- Dockerfile | 2 +- Makefile | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 83634bc..2adf80e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:lts-alpine AS builder +FROM --platform=$BUILDPLATFORM node:lts-alpine AS builder WORKDIR /app COPY sigl sigl diff --git a/Makefile b/Makefile index e246aa2..16ea85f 100644 --- a/Makefile +++ b/Makefile @@ -24,6 +24,12 @@ db-upgrade : db-downgrade : poetry run flask db downgrade +docker : + docker buildx build --platform=linux/amd64,linux/arm64 . -t asymworks/sigl:latest + +docker-deploy: + docker buildx build --platform=linux/amd64,linux/arm64 . -t asymworks/sigl:latest --push + lint : poetry run flake8 @@ -48,7 +54,7 @@ test-x : test-wip : poetry run python -m pytest tests -m wip -.PHONY : css \ +.PHONY : css docker \ db-init db-migrate db-upgrad db-downgrade \ lint shell serve \ requirements.txt requirements-dev.txt \