-
Notifications
You must be signed in to change notification settings - Fork 1
61 lines (50 loc) · 1.32 KB
/
build.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
name: Build
on: push
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- name: Setup toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Rust cache
uses: Swatinem/rust-cache@v1
- name: Install Node.js, NPM and Yarn
uses: actions/setup-node@v2
with:
node-version: "16.7.0"
- name: Install node modules
run: npm i
working-directory: ./client
- name: Setup wasm-pack
uses: jetli/[email protected]
with:
version: 'latest'
- name: Build static files
run: ./script/build_client.sh
- name: Build server
uses: actions-rs/cargo@v1
with:
command: build
args: --bin server --release
- name: Run
run:
chmod +x ./target/release/server
./script/run_on_ci.sh
- name: Archive debug artifacts
uses: actions/upload-artifact@v2
with:
name: build
path: |
target/release/server
server/templates
static/
Rocket.toml
DEPLOY.md
Dockerfile
docker-compose.yml
!static/.gitignore