From 09a610e1282b406589f76fdf6587cc81dea4d06c Mon Sep 17 00:00:00 2001 From: Kasra Bigdeli Date: Sat, 7 Aug 2021 16:43:52 -0700 Subject: [PATCH] Pushing edge to DockerHub --- dev-scripts/build_and_push_edge.sh | 4 ++-- dockerfile-captain.edge | 2 +- dockerfile-captain.release | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/dev-scripts/build_and_push_edge.sh b/dev-scripts/build_and_push_edge.sh index 901d74d..1776e75 100755 --- a/dev-scripts/build_and_push_edge.sh +++ b/dev-scripts/build_and_push_edge.sh @@ -45,8 +45,8 @@ docker buildx ls docker buildx create --name mybuilder docker buildx use mybuilder -docker buildx build --platform linux/arm -t $IMAGE_NAME:$CAPROVER_VERSION -t $IMAGE_NAME:latest -f dockerfile-captain.edge --push . -# docker buildx build --platform linux/amd64,linux/arm64,linux/arm -t $IMAGE_NAME:$CAPROVER_VERSION -t $IMAGE_NAME:latest -f dockerfile-captain.edge --push . +# docker buildx build --platform linux/arm -t $IMAGE_NAME:$CAPROVER_VERSION -t $IMAGE_NAME:latest -f dockerfile-captain.edge --push . +docker buildx build --platform linux/amd64,linux/arm64,linux/arm -t $IMAGE_NAME:$CAPROVER_VERSION -t $IMAGE_NAME:latest -f dockerfile-captain.edge --push . # docker build -t $IMAGE_NAME:$CAPROVER_VERSION -t $IMAGE_NAME:latest -f dockerfile-captain.edge . # docker push $IMAGE_NAME:latest diff --git a/dockerfile-captain.edge b/dockerfile-captain.edge index 5872bc1..c6c9c48 100644 --- a/dockerfile-captain.edge +++ b/dockerfile-captain.edge @@ -29,7 +29,7 @@ RUN curl -Iv https://registry.yarnpkg.com/@ant-design/icons-svg/-/icons-svg-4.1. git clone https://github.com/githubsaturn/caprover-frontend.git && \ cd caprover-frontend && \ git log --max-count=1 && \ - yarn install --no-cache --frozen-lockfile --production && echo "Installation finished" && \ + yarn install --no-cache --frozen-lockfile --production --network-timeout 600000 && echo "Installation finished" && \ yarn run build && echo "Building finished" && \ mv ./build ../../app/dist-frontend && \ cd / && \ diff --git a/dockerfile-captain.release b/dockerfile-captain.release index e4b867e..b0662c4 100644 --- a/dockerfile-captain.release +++ b/dockerfile-captain.release @@ -17,11 +17,13 @@ RUN npm ci --production && \ ENV FRONTEND_COMMIT_HASH c28107f530ef23a87aee503cc2ac815a822edeee -RUN mkdir -p /usr/src/app-frontend && cd /usr/src/app-frontend && \ +# armV7 fails: https://github.com/yarnpkg/yarn/issues/5259 https://github.com/nodejs/docker-node/issues/1335 +RUN curl -Iv https://registry.yarnpkg.com/@ant-design/icons-svg/-/icons-svg-4.1.0.tgz && \ + mkdir -p /usr/src/app-frontend && cd /usr/src/app-frontend && \ git clone https://github.com/githubsaturn/caprover-frontend.git && \ cd caprover-frontend && \ git reset --hard ${FRONTEND_COMMIT_HASH} && \ - yarn install --no-cache --frozen-lockfile --production && echo "Installation finished" && \ + yarn install --no-cache --frozen-lockfile --production --network-timeout 600000 && echo "Installation finished" && \ yarn run build && echo "Building finished" && \ mv ./build ../../app/dist-frontend && \ cd / && \