-
Notifications
You must be signed in to change notification settings - Fork 22
56 lines (44 loc) · 1.65 KB
/
damocles-worker.yaml
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
name: damocles-worker
on:
pull_request:
branches: ["main", "release/**", "dev/coop/**"]
paths-ignore: ["*.md", "docs/**"]
push:
branches: ["main", "release/**", "dev/coop/**"]
paths-ignore: ["*.md", "docs/**"]
jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
sudo apt update && sudo apt install --reinstall ocl-icd-opencl-dev libhwloc-dev -y
wget https://github.com/gnprice/toml-cli/releases/download/v0.2.3/toml-0.2.3-x86_64-linux.tar.gz && tar -xzf toml-0.2.3-x86_64-linux.tar.gz
sudo mv toml-0.2.3-x86_64-linux/toml /usr/local/bin
rm -rf toml-0.2.3-x86_64-linux.tar.gz toml-0.2.3-x86_64-linux
- name: Read rust toolchain
id: read-rust-toolchain
run: |
echo "toolchain=$(toml get ./rust-toolchain.toml toolchain.channel --raw)" >> "$GITHUB_OUTPUT"
- name: Setup rust
run: rustup toolchain install ${{ steps.read-rust-toolchain.outputs.toolchain }} --profile minimal
- uses: Swatinem/rust-cache@v2
continue-on-error: false
- name: test damocles-worker
run: make test-worker
- name: build damocles-worker
run: make build-worker
- name: check damocles-worker
run: make check-worker
- name: check git dirty
run: make check-git
- name: show bins
run: ls -lha ./dist/bin/
# - name: upload damocles-worker
# uses: actions/upload-artifact@v2
# with:
# name: damocles-worker
# path: ./dist/bin/
# if-no-files-found: error
# retention-days: 3