Skip to content

test linux arm64 build #1

test linux arm64 build

test linux arm64 build #1

name: Desktop Release - Test Linux arm64 build
on:
workflow_dispatch:
push:
branches:
- 'fix/linux-arm64-build'
jobs:
Linux-AppImage-ARM64-Test:
name: Test Linux AppImage ARM64
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/desktop
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc'
cache: 'yarn'
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install FPM
run: sudo gem install fpm -f
- run: yarn install --immutable
- name: Rebuild Electron Native Modules
run: yarn workspace @standardnotes/desktop rebuild:home-server
- run: yarn build:desktop
- run: echo APP_VERSION=$(node -p "require('./../web/package.json').version") >> $GITHUB_ENV
- name: Compile for AppImage
run: yarn run webpack --config desktop.webpack.prod.js
- name: AppImageArm64
run: |
yarn workspace @standardnotes/desktop rebuild:home-server --arch arm64 --platform linux
yarn run electron-builder --linux --arm64 -c.linux.target=AppImage --publish=never --c.extraMetadata.version=${{ env.APP_VERSION }}
env:
npm_config_target_arch: 'arm64'
npm_config_arch: 'arm64'
npm_config_platform: 'linux'
- name: Verify Build
run: |
echo "Checking if AppImage was created..."
ls -lh dist/*.AppImage
echo "Extracting AppImage..."
dist/standard-notes-*-linux-arm64.AppImage --appimage-extract
echo "Verifying main binary architecture..."
file squashfs-root/standard-notes
echo "Verifying keytar native module..."
file squashfs-root/resources/app.asar.unpacked/node_modules/keytar/build/Release/keytar.node
echo "Verifying sqlite3 native module..."
file squashfs-root/resources/app.asar.unpacked/node_modules/sqlite3/lib/binding/napi-v6-linux-unknown-arm64/node_sqlite3.node
echo "All native modules should be 'ELF 64-bit LSB ... ARM aarch64'"
- name: Upload Test Artifact
uses: actions/upload-artifact@v4.0.0
with:
name: test-arm64-appimage
path: |
packages/desktop/dist/*.AppImage
packages/desktop/dist/*.yml