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

[DRAFT] Add ability to build deb files on aarch64 #4762

Closed
wants to merge 17 commits into from
Closed
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
57 changes: 57 additions & 0 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,63 @@ concurrency:
cancel-in-progress: true

jobs:
build-and-upload-release-artifacts-aarch64:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- arch: aarch64
distro: ubuntu_latest
csc_link_secret: ''
csc_key_password_secret: ''
steps:
- uses: uraimo/run-on-arch-action@v2
with:
run: uname -a

- name: Install updated fpm
run: sudo apt-get install ruby-dev build-essential && sudo gem i fpm -f

- uses: actions/checkout@v3
name: Checkout branch

- name: Setup Node
uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'

- name: Bootstrap packages
run: npm run bootstrap

- name: Package app
shell: bash
run: npm run app-package
env:
CSC_LINK: ${{ matrix.csc_link_secret != '' && secrets[matrix.csc_link_secret] || '' }}
CSC_KEY_PASSWORD: ${{ matrix.csc_key_password_secret != '' && secrets[matrix.csc_key_password_secret] || '' }}

- name: Setup Inso CLI version env var
run:
echo "INSO_VERSION=$(jq .version packages/insomnia-inso/package.json -rj)" >> $GITHUB_ENV

- name: Package inso
run: USE_SYSTEM_FPM=true npm run inso-package
env:
VERSION: ${{ env.INSO_VERSION }}

- name: Create inso artifacts
run: USE_SYSTEM_FPM=true npm run inso-package:artifacts

- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
if-no-files-found: ignore
name: ${{ matrix.os }}-${{matrix.arch}}-artifacts
path: |
packages/insomnia/dist/*.deb


build-and-upload-release-artifacts:
runs-on: ${{ matrix.os }}
strategy:
Expand Down
48 changes: 48 additions & 0 deletions .github/workflows/release-recurring.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,54 @@ concurrency:
env:
PR_NUMBER: ${{ github.event.number }}
jobs:
build-and-upload-release-artifacts-aarch64:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- arch: aarch64
distro: ubuntu_latest
build-targets: "deb"
os: ubuntu-latest
steps:
- uses: actions/checkout@v3
name: Checkout branch
- uses: uraimo/run-on-arch-action@v2
name: setup aarch container
with:
arch: ${{ matrix.arch }}
distro: ${{ matrix.distro }}
# Not required, but speeds up builds
githubToken: ${{ github.token }}
shell: /bin/sh
# Mount the artifacts directory as /artifacts in the container
dockerRunArgs: |
--volume \"${PWD}:/app\"
install: |
apt update
apt install -y curl ruby-dev build-essential
curl -sL https://deb.nodesource.com/setup_16.x | bash -
apt install -y nodejs
gem i fpm -f
npm install -g npm@latest
run: |
cd /app
npm config set -g user=`whoami`
npm install -g n
n `cat .nvmrc`
npm install
npm run bootstrap
BUILD_REF="$(git rev-parse --short HEAD)${{ github.event_name == 'pull_request' && '.pr-$PR_NUMBER' || '' }}" npm run app-bump-version
USE_SYSTEM_FPM=true BUILD_TARGETS='${{ matrix.build-targets }}' npm run app-package
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
if-no-files-found: ignore
name: ${{ matrix.os }}-${{matrix.arch}}-artifacts-${{ github.run_number }}
path: |
packages/insomnia/dist/*.deb

build-and-upload-artifacts:
# Skip jobs for release PRs
if: "!startsWith(github.head_ref, 'release/')"
Expand Down