Skip to content

Commit

Permalink
Added ARM64 linux-musl builds.
Browse files Browse the repository at this point in the history
  • Loading branch information
uhop committed Aug 22, 2024
1 parent 0e3b06f commit ba014d0
Show file tree
Hide file tree
Showing 10 changed files with 115 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .github/actions/linux-arm64-alpine-node-18/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM --platform=linux/arm64 node:18-alpine

RUN apk add --no-cache python3 make gcc g++ linux-headers

COPY entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
7 changes: 7 additions & 0 deletions .github/actions/linux-arm64-alpine-node-18/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: 'Create a binary artifact for Node 18 on Alpine Linux'
description: 'Create a binary artifact for Node 18 on Alpine Linux using musl'
runs:
using: 'docker'
image: 'Dockerfile'
args:
- ${{inputs.node-version}}
10 changes: 10 additions & 0 deletions .github/actions/linux-arm64-alpine-node-18/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/sh

set -e

export USERNAME=`whoami`
export DEVELOPMENT_SKIP_GETTING_ASSET=true
npm i
npm run build --if-present
npm test
npm run save-to-github
6 changes: 6 additions & 0 deletions .github/actions/linux-arm64-alpine-node-20/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM --platform=linux/arm64 node:20-alpine

RUN apk add --no-cache python3 make gcc g++ linux-headers

COPY entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
7 changes: 7 additions & 0 deletions .github/actions/linux-arm64-alpine-node-20/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: 'Create a binary artifact for Node 20 on Alpine Linux'
description: 'Create a binary artifact for Node 20 on Alpine Linux using musl'
runs:
using: 'docker'
image: 'Dockerfile'
args:
- ${{inputs.node-version}}
10 changes: 10 additions & 0 deletions .github/actions/linux-arm64-alpine-node-20/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/sh

set -e

export USERNAME=`whoami`
export DEVELOPMENT_SKIP_GETTING_ASSET=true
npm i
npm run build --if-present
npm test
npm run save-to-github
6 changes: 6 additions & 0 deletions .github/actions/linux-arm64-alpine-node-22/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
FROM --platform=linux/arm64 node:22-alpine

RUN apk add --no-cache python3 make gcc g++ linux-headers

COPY entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
7 changes: 7 additions & 0 deletions .github/actions/linux-arm64-alpine-node-22/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: 'Create a binary artifact for Node 22 on Alpine Linux'
description: 'Create a binary artifact for Node 22 on Alpine Linux using musl'
runs:
using: 'docker'
image: 'Dockerfile'
args:
- ${{inputs.node-version}}
10 changes: 10 additions & 0 deletions .github/actions/linux-arm64-alpine-node-22/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/sh

set -e

export USERNAME=`whoami`
export DEVELOPMENT_SKIP_GETTING_ASSET=true
npm i
npm run build --if-present
npm test
npm run save-to-github
46 changes: 46 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,3 +197,49 @@ jobs:
uses: ./.github/actions/linux-arm64-node-22/
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

build-linux-arm64-alpine-node-18:
name: Node.js 18 on Alpine Linux on ARM64
needs: create-release
runs-on: ubuntu-latest
continue-on-error: true

steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Install, test, and create artifact
uses: ./.github/actions/linux-arm64-alpine-node-18/
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

build-linux-arm64-alpine-node-20:
name: Node.js 20 on Alpine Linux on ARM64
needs: create-release
runs-on: ubuntu-latest
continue-on-error: true

steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Install, test, and create artifact
uses: ./.github/actions/linux-arm64-alpine-node-20/
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

build-linux-arm64-alpine-node-22:
name: Node.js 22 on Alpine Linux on ARM64
needs: create-release
runs-on: ubuntu-latest
continue-on-error: true

steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Install, test, and create artifact
uses: ./.github/actions/linux-arm64-alpine-node-22/
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

0 comments on commit ba014d0

Please sign in to comment.