-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (44 loc) · 1.84 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
name: Raspberry Pi package
on:
release:
types: [published]
jobs:
build:
permissions: write-all
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: pguyot/[email protected]
with:
base_image: https://dietpi.com/downloads/images/DietPi_RPi-ARMv8-Bullseye.7z
cpu: cortex-a53
bind_mount_repository: true
image_additional_mb: 10240
optimize_image: false
commands: |
# Rust complains (rightly) that $HOME doesn't match eid home
export HOME=/root
# Workaround to CI worker being stuck on Updating crates.io index
export CARGO_REGISTRIES_CRATES_IO_PROTOCOL=sparse
# Install setup prerequisites
apt-get update -y --allow-releaseinfo-change
apt-get upgrade -y
apt-get autoremove -y
apt-get install curl
curl https://sh.rustup.rs -sSf | sh -s -- -y
. "$HOME/.cargo/env"
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash
# Install framework specific packages
apt-get install -y nodejs
# Install build tools and tauri-cli requirements
apt-get install -y libwebkit2gtk-4.0-dev build-essential wget libssl-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev
cargo install tauri-cli
# Install frontend dependencies
npm install
# Build the application
cargo tauri build --config '{"package": {"version": "${{ github.event.release.tag_name }}"}}'
- name: Upload Release Asset
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run:
gh release upload ${{ github.event.release.tag_name }} ${{ github.workspace }}/src-tauri/target/release/bundle/deb/home-display*.deb