Headless Release #12
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Headless Release | |
| # Dispatch-only smoke test for the headless tarball pack across the | |
| # three supported platforms. The canonical tag-driven release runs the | |
| # same matrix inside .github/workflows/release.yml — this file lets us | |
| # validate a headless build on a branch (or via the Actions UI) without | |
| # cutting a tag. | |
| on: | |
| workflow_dispatch: | |
| jobs: | |
| pack: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - runs-on: macos-14 | |
| platform: darwin-arm64 | |
| - runs-on: ubuntu-22.04 | |
| platform: linux-x64 | |
| - runs-on: ubuntu-22.04-arm | |
| platform: linux-arm64 | |
| # darwin-x64 (Intel Mac) is intentionally omitted — the | |
| # macos-13 runner queue is so backed up that jobs sit | |
| # unassigned for an hour. Add it back when GitHub's runner | |
| # supply recovers, or move to macos-13-large. | |
| runs-on: ${{ matrix.runs-on }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # The Node version here MUST match NODE_VERSION in | |
| # scripts/pack-headless.mjs — the embedded Node binary in the | |
| # tarball is downloaded for that version, and node-pty's pty.node | |
| # is rebuilt against its ABI. Bumping one without the other gives | |
| # a broken tarball at runtime. | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22.12.0' | |
| # npm has a long-running bug (#4828) where optional native deps | |
| # (rolldown's per-platform .node binding here) aren't always | |
| # installed off a cross-platform package-lock.json with | |
| # --legacy-peer-deps. Wiping both forces clean re-resolution per | |
| # runner. We can't use the npm cache for the same reason, so | |
| # setup-node above intentionally has no `cache: 'npm'`. | |
| - name: Install dependencies | |
| run: | | |
| rm -rf node_modules package-lock.json | |
| npm install --legacy-peer-deps | |
| - name: Build headless bundle | |
| run: npm run build:headless | |
| - name: Pack tarball | |
| run: npm run pack:headless | |
| - name: Upload workflow artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: harness-server-${{ matrix.platform }} | |
| path: | | |
| release/headless/harness-server-*-${{ matrix.platform }}.tar.gz | |
| release/headless/harness-server-*-${{ matrix.platform }}.tar.gz.sha256 | |
| if-no-files-found: error |