Skip to content

Commit 511ef44

Browse files
test
1 parent bfd63b1 commit 511ef44

File tree

1 file changed

+67
-0
lines changed

1 file changed

+67
-0
lines changed
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: Build and Extract Janus Binaries
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
13+
strategy:
14+
matrix:
15+
platform: [linux/amd64, linux/arm64, darwin/amd64, darwin/arm64, windows/amd64, windows/arm64]
16+
17+
steps:
18+
- name: Checkout Code
19+
uses: actions/checkout@v4
20+
21+
- name: Set up QEMU for Multi-Arch
22+
uses: docker/setup-qemu-action@v3
23+
24+
- name: Set up Docker Buildx
25+
uses: docker/setup-buildx-action@v3
26+
27+
- name: Build Janus for ${{ matrix.platform }}
28+
run: |
29+
docker buildx create --use
30+
docker buildx build \
31+
--platform=${{ matrix.platform }} \
32+
--output type=local,dest=./output-${{ matrix.platform }} ./JanusCoreDeps
33+
34+
- name: List Extracted Binaries
35+
run: ls -lh ./output-${{ matrix.platform }}/opt/janus
36+
37+
- name: Upload Janus Binaries as Artifacts
38+
uses: actions/upload-artifact@v4
39+
with:
40+
name: janus-binary-${{ matrix.platform }}
41+
path: ./output-${{ matrix.platform }}/opt/janus
42+
43+
publish:
44+
needs: build
45+
runs-on: ubuntu-latest
46+
steps:
47+
- name: Checkout Code
48+
uses: actions/checkout@v4
49+
50+
- name: Download All Binaries
51+
uses: actions/download-artifact@v4
52+
with:
53+
path: bin/
54+
55+
- name: Organize Binaries
56+
run: |
57+
mkdir -p release
58+
mv bin/janus-binary-*/* release/
59+
ls -lh release/
60+
61+
- name: Commit and Push Binaries
62+
run: |
63+
git config --global user.name "github-actions"
64+
git config --global user.email "github-actions@github.com"
65+
git add release/
66+
git commit -m "Update Janus binaries" || echo "No changes to commit"
67+
git push

0 commit comments

Comments
 (0)