🐳 Fix Docker arm/v7 support

This commit is contained in:
Alicia Sykes 2024-03-04 13:00:17 +00:00
parent 2caec6a8a9
commit 0d79fcf8a5
3 changed files with 25 additions and 5 deletions

View File

@ -14,6 +14,13 @@ on:
- '.github/workflows/docker-build-publish.yml'
- 'Dockerfile'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
packages: write
env:
DH_IMAGE: ${{ secrets.DOCKER_REPO }}
GH_IMAGE: ${{ github.repository_owner }}/${{ github.event.repository.name }}
@ -52,9 +59,22 @@ jobs:
- name: 🔧 Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: linux/amd64,linux/arm64,linux/arm/v7
- name: 🔧 Set up Docker Buildx
uses: docker/setup-buildx-action@v1
id: buildx
with:
driver-opts: image=moby/buildkit:v0.10.6
- name: 👀 Inspect builder
run: |
echo "Name: ${{ steps.buildx.outputs.name }}"
echo "Endpoint: ${{ steps.buildx.outputs.endpoint }}"
echo "Status: ${{ steps.buildx.outputs.status }}"
echo "Flags: ${{ steps.buildx.outputs.flags }}"
echo "Platforms: ${{ steps.buildx.outputs.platforms }}"
- name: 🔑 Login to DockerHub
uses: docker/login-action@v1

View File

@ -1,4 +1,4 @@
FROM node:20.11.1-alpine AS BUILD_IMAGE
FROM node:18.19.1-alpine AS BUILD_IMAGE
# Set the platform to build image for
ARG TARGETPLATFORM
@ -22,10 +22,10 @@ RUN yarn install --ignore-engines --immutable --no-cache --network-timeout 30000
COPY . ./
# Build initial app for production
RUN NODE_OPTIONS=--openssl-legacy-provider yarn build --mode production
RUN yarn build --mode production
# Production stage
FROM node:20.11.1-alpine
FROM node:20.11.1-alpine3.19
# Define some ENV Vars
ENV PORT=80 \

View File

@ -1,5 +1,5 @@
{
"name": "Dashy",
"name": "dashy",
"version": "2.1.2",
"license": "MIT",
"main": "server",
@ -7,7 +7,7 @@
"scripts": {
"start": "node server",
"dev": "vue-cli-service serve",
"build": "vue-cli-service build",
"build": "NODE_OPTIONS=--openssl-legacy-provider vue-cli-service build",
"lint": "vue-cli-service lint",
"pm2-start": "npx pm2 start server.js",
"build-watch": "vue-cli-service build --watch --mode production",