mirror of
https://github.com/Kong/insomnia.git
synced 2026-04-18 05:08:40 -04:00
104 lines
3.3 KiB
YAML
104 lines
3.3 KiB
YAML
name: Release Recurring
|
|
# This workflow bakes executables of the major platforms for Testing purposes
|
|
on:
|
|
merge_group:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- develop
|
|
pull_request:
|
|
types:
|
|
- opened
|
|
- synchronize
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
env:
|
|
PR_NUMBER: ${{ github.event.number }}
|
|
jobs:
|
|
build-and-upload-artifacts:
|
|
timeout-minutes: 45
|
|
# Skip jobs for release PRs
|
|
# windows on recurring should be portable
|
|
if: ${{ !startsWith(github.head_ref, 'release/') }}
|
|
runs-on: ${{ matrix.os }}
|
|
permissions:
|
|
packages: read
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
- os: macos-latest-large
|
|
build-targets: zip
|
|
- os: windows-latest
|
|
build-targets: portable
|
|
- os: ubuntu-24.04
|
|
build-targets: tar.gz
|
|
- os: ubuntu-24.04-arm
|
|
build-targets: tar.gz
|
|
steps:
|
|
- name: Checkout branch
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Setup Node
|
|
uses: actions/setup-node@v6
|
|
with:
|
|
node-version-file: '.nvmrc'
|
|
cache: 'npm'
|
|
cache-dependency-path: package-lock.json
|
|
registry-url: 'https://npm.pkg.github.com'
|
|
scope: '@kong'
|
|
|
|
- name: Install packages
|
|
run: npm ci
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: '1'
|
|
|
|
- name: Install x64 version of native Mac dependencies
|
|
run: npm run install-x64-native-dependencies -w insomnia
|
|
if: ${{ matrix.os == 'macos-latest-large' }}
|
|
|
|
- name: Bump version
|
|
shell: bash
|
|
run: npm --workspaces version prerelease --preid="alpha-pr-$(git rev-parse --short HEAD)" --no-git-tag-version
|
|
|
|
- name: Package
|
|
shell: bash
|
|
run: NODE_OPTIONS='--max_old_space_size=6144' BUILD_TARGETS='${{ matrix.build-targets }}' npm run app-package
|
|
|
|
- name: Build and verify secure wrapper (Windows)
|
|
if: ${{ matrix.os == 'windows-latest' }}
|
|
shell: bash
|
|
run: NODE_OPTIONS='--max_old_space_size=6144' ./build-secure-wrapper.sh
|
|
|
|
# See https://github.com/electron/electron/issues/42510#issuecomment-2171583086
|
|
- if: ${{ runner.os == 'Linux' }}
|
|
name: Lift unprivileged user namespace restrictions
|
|
run: sudo sysctl kernel/apparmor_restrict_unprivileged_userns=0
|
|
|
|
- name: Test critical path on packaged electron app
|
|
run: npm run test:crit:package
|
|
env:
|
|
INSOMNIA_UPDATES_URL: http://localhost:4010
|
|
|
|
- name: Upload smoke test traces
|
|
uses: actions/upload-artifact@v7
|
|
if: failure()
|
|
with:
|
|
if-no-files-found: ignore
|
|
name: ${{ matrix.os }}-package-critical-test-traces-${{ github.run_number }}
|
|
path: packages/insomnia-smoke-test/traces
|
|
|
|
- name: Upload artifacts
|
|
uses: actions/upload-artifact@v7
|
|
with:
|
|
if-no-files-found: ignore
|
|
name: ${{ matrix.os }}-artifacts-${{ github.run_number }}
|
|
path: |
|
|
packages/insomnia/dist/*.exe
|
|
packages/insomnia/dist/*.tar.gz
|
|
packages/insomnia/dist/*.zip
|
|
packages/insomnia/dist/*.yml
|
|
packages/insomnia/dist/squirrel-windows/*.exe
|