forked from T-REX-XP/RRManager
-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (57 loc) · 1.73 KB
/
ci.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
name: CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
target:
- "x64-7.0"
- "aarch64-7.0"
include:
- target: x64-7.0
dsm_ver: 7.0
- target: aarch64-7.0
dsm_ver: 7.0
steps:
- uses: actions/checkout@v4
# Install Node.js
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '16' # Specify the Node.js version you need
# Install npm dependencies (including Webpack)
- name: Install Dependencies
run: npm install
# Run Webpack build
- name: Webpack Build
run: npm run build
- name: Checkout SynoCommunity Source and Docker Image
run: |
git clone https://github.com/SynoCommunity/spksrc.git /home/runner/work/spksrc
docker pull ghcr.io/synocommunity/spksrc
- name: Install UPX
uses: crazy-max/ghaction-upx@v3
with:
install-only: true
- name: Build Package
run: |
workdir=$(pwd)
docker run -v /home/runner/work/spksrc:/spksrc \
-v $workdir:/spksrc/spk/rr-manager \
-v $workdir/packages:/spksrc/packages \
-w /spksrc/spk/rr-manager \
ghcr.io/synocommunity/spksrc \
make arch-${{ matrix.target }}
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: packages/*.spk
- name: Save Primes
id: cache-primes-save
uses: actions/cache/save@v4
with:
path: |
/home/runner/work/spksrc/distrib
key: ${{ steps.cache-primes-restore.outputs.cache-primary-key }}