-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (71 loc) · 1.88 KB
/
Copy pathbuild.yml
File metadata and controls
79 lines (71 loc) · 1.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: build
on:
push:
tags:
- "*"
workflow_dispatch:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-26.04
arch: x86_64
- os: ubuntu-26.04-arm
arch: aarch64
steps:
- name: checkout
uses: actions/checkout@v7
- name: build-image
run: |
pushd "$(mktemp -d)"
curl -f -L https://github.com/haskell-wasm/rust-alpine-mimalloc/archive/refs/heads/master.tar.gz | tar xz --strip-components=1
podman build \
--pull \
--tag rust:alpine-mimalloc \
.
popd
- name: build-node
run: |
podman run \
--init \
--rm \
--volume $PWD:/workspace \
--workdir /workspace \
rust:alpine-mimalloc \
/workspace/build-alpine.sh
- name: upload-artifact
uses: actions/upload-artifact@v7
with:
name: node-linux-${{ matrix.arch }}
path: dist/node-v*.tar.xz
- name: test-node
run: |
pushd dist
tar xJf node-v*.tar.xz --strip-components=1
export PATH=$PWD/bin:$PATH
npm install @bjorn3/browser_wasi_shim
popd
release:
if: github.event_name == 'push'
needs: build
runs-on: ubuntu-slim
permissions:
contents: write
steps:
- name: download-artifacts
uses: actions/download-artifact@v8
with:
merge-multiple: true
- name: publish-release
env:
GH_TOKEN: ${{ github.token }}
GH_REPO: ${{ github.repository }}
run: |
gh release create ${{ github.ref_name }} node-v*.tar.xz \
--title ${{ github.ref_name }} \
--notes-file /dev/null \
--latest \
--verify-tag