-
Notifications
You must be signed in to change notification settings - Fork 88
67 lines (54 loc) · 1.72 KB
/
build_local_backend.yml
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
name: Build and Test Convex Backend
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
env:
RUST_BACKTRACE: 1
jobs:
build_and_test:
name: Build and Test Convex Backend
runs-on: [self-hosted, aws, x64, xlarge]
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Rust
uses: ./.github/actions/setup-rust
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
r2-access-key: ${{ secrets.R2_ACCESS_KEY_ID }}
r2-secret-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
- name: Check Cargo.lock up-to-date
run: cargo update -w --locked
- name: Cache pnpm artifacts
uses: runs-on/cache@v4
env:
AWS_REGION: ${{ vars.AWS_REGION }}
RUNS_ON_S3_BUCKET_CACHE: ${{ vars.RUNS_ON_S3_BUCKET_CACHE }}
with:
path: |
npm-packages/common/temp/build-cache
npm-packages/common/temp/pnpm-store
key: pnpm-cache-${{
hashFiles('npm-packages/common/config/rush/pnpm-lock.yaml') }}-2
restore-keys: pnpm-cache-
- name: Node setup
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
- name: NPM install globals
run: npm ci --prefix scripts
- name: Install JS
run: |
just rush install
just rush build
- name: Install cargo-nextest
uses: taiki-e/install-action@cargo-nextest
- name: Build rust tests
run: cargo nextest run --no-run --profile ci
- name: Run Rust tests
run: cargo nextest run --profile ci