diff --git a/armhf.Dockerfile b/armhf.Dockerfile index 8e64259..7f192be 100644 --- a/armhf.Dockerfile +++ b/armhf.Dockerfile @@ -1,11 +1,15 @@ -FROM arm32v7/alpine:3.12 as frontend +FROM alpine:3.12 as frontend RUN apk add --no-cache \ - npm + npm \ + curl RUN npm install -g @angular/cli WORKDIR /build + +RUN curl -L https://github.com/balena-io/qemu/releases/download/v3.0.0%2Bresin/qemu-3.0.0+resin-arm.tar.gz | tar zxvf - -C . && mv qemu-3.0.0+resin-arm/qemu-arm-static . + COPY [ "package.json", "package-lock.json", "/build/" ] RUN npm install @@ -17,7 +21,7 @@ RUN ng build --prod FROM arm32v7/alpine:3.12 -COPY qemu-arm-static /usr/bin +COPY --from=frontend /build/qemu-arm-static /usr/bin ENV UID=1000 \ GID=1000 \ diff --git a/hooks/post_checkout b/hooks/post_checkout deleted file mode 100644 index 326c943..0000000 --- a/hooks/post_checkout +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash -# downloads a local copy of qemu on docker-hub build machines -curl -L https://github.com/balena-io/qemu/releases/download/v3.0.0%2Bresin/qemu-3.0.0+resin-arm.tar.gz | tar zxvf - -C . && mv qemu-3.0.0+resin-arm/qemu-arm-static . \ No newline at end of file diff --git a/hooks/pre_build b/hooks/pre_build deleted file mode 100644 index 076769d..0000000 --- a/hooks/pre_build +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash -# Register qemu-*-static for all supported processors except the -# current one, but also remove all registered binfmt_misc before -docker run --rm --privileged multiarch/qemu-user-static:register --reset \ No newline at end of file