Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] 🐳 Adds back Docker arm/v7 support #1492

Merged
merged 5 commits into from
Mar 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/workflows/docker-build-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }}
Expand Down Expand Up @@ -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
Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -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
Expand All @@ -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 \
Expand Down
12 changes: 5 additions & 7 deletions netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,12 @@
command = "yarn build"
publish = "dist"
functions = "services/serverless-functions"
environment = { NODE_VERSION = "16.13.2" }

# Site info, used for the 1-Click deploy page
[template.environment]
STATUSKIT_PAGE_TITLE = "Dashy"
STATUSKIT_COMPANY_LOGO = "https://raw.githubusercontent.com/Lissy93/dashy/master/docs/assets/logo.png"
STATUSKIT_SUPPORT_CONTACT_LINK = "https://github.com/lissy93/dashy"
STATUSKIT_RESOURCES_LINK = "https://dashy.to/docs"
# Environmental variables for build command
[build.environment]
NODE_VERSION = "20.11.1"
NODE_OPTIONS = "--openssl-legacy-provider"
YARN_FLAGS = "--ignore-engines"

# Redirect the Node endpoints to serverless functions
[[redirects]]
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "Dashy",
"name": "dashy",
"version": "2.1.2",
"license": "MIT",
"main": "server",
"author": "Alicia Sykes <alicia@omg.lol> (https://aliciasykes.com)",
"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",
Expand Down
Loading