Skip to content

Commit

Permalink
Add Linux prebuilt binaries for armv7 and arm64 and other improve…
Browse files Browse the repository at this point in the history
…ments (#758)

* Add support for alpine prebuilt binaries on `armv7`

This job now uses the `checkout` action making it much cleaner and reliable.

* Add support for Linux prebuilt binaries on `armv7` & `arm64`
  • Loading branch information
m4heshd authored Apr 7, 2022
1 parent fa58644 commit 5e07181
Showing 1 changed file with 29 additions and 5 deletions.
34 changes: 29 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,39 @@ jobs:
- run: npm install --ignore-scripts
- run: npx --no-install prebuild -r node -t 10.20.0 -t 12.0.0 -t 14.0.0 -t 16.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}

prebuild-arm64-alpine:
name: Prebuild on arm64 alpine
prebuild-alpine-arm:
strategy:
matrix:
arch:
- arm/v7
- arm64
name: Prebuild on alpine (${{ matrix.arch }})
runs-on: ubuntu-latest
needs: publish
steps:
- uses: actions/checkout@v2
- uses: docker/setup-qemu-action@v1
- run: |
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:16-alpine -c "\
apk add build-base git python3 --update-cache && \
cd /tmp/project && \
npm install --ignore-scripts && \
npx --no-install prebuild -r node -t 10.20.0 -t 12.0.0 -t 14.0.0 -t 16.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}"
prebuild-linux-arm:
strategy:
matrix:
arch:
- arm/v7
- arm64
name: Prebuild on Linux (${{ matrix.arch }})
runs-on: ubuntu-latest
needs: publish
steps:
- uses: actions/checkout@v2
- uses: docker/setup-qemu-action@v1
- run: |
docker run --rm --entrypoint /bin/sh --platform linux/arm64 node:16-alpine -c "apk add build-base git python3 --update-cache && \
git clone ${{ github.event.repository.clone_url }} && \
cd ${{ github.event.repository.name }} && \
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:16 -c "\
cd /tmp/project && \
npm install --ignore-scripts && \
npx --no-install prebuild -r node -t 10.20.0 -t 12.0.0 -t 14.0.0 -t 16.0.0 --include-regex 'better_sqlite3.node$' -u ${{ secrets.GITHUB_TOKEN }}"

0 comments on commit 5e07181

Please sign in to comment.