forked from cage-kiosk/cage
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (37 loc) · 1.08 KB
/
compile.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
name: Artefact builder
on:
push:
branches:
- internal
tags:
- v*.*.*
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build
run: |
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 --output=type=local,dest=dist .
mv dist/linux_amd64/app/build/cage dist/cage-amd64
mv dist/linux_arm64/app/build/cage dist/cage-arm64
mv dist/linux_arm_v7/app/build/cage dist/cage-armhf
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: cage-binaries
path: dist/cage-*
retention-days: 1
- name: create release
if: startsWith(github.ref, 'refs/tags/v')
uses: ncipollo/release-action@v1
with:
artifacts: "dist/cage-*"
token: ${{ secrets.GITHUB_TOKEN }}