Skip to content

Commit e95e108

Browse files
committed
chore: build linux binaries for multiple archs
1 parent 9bf93fb commit e95e108

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/release.yml

+36
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,42 @@ on:
77
- 'edited'
88

99
jobs:
10+
build-linux:
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
platform:
15+
- os: linux
16+
arch: amd64
17+
- os: linux
18+
arch: arm64
19+
20+
runs-on: 'ubuntu-latest'
21+
22+
steps:
23+
- name: Check out code
24+
uses: actions/checkout@v4
25+
- name: Set up QEMU
26+
uses: docker/setup-qemu-action@v3
27+
- name: Set up Docker Buildx
28+
uses: docker/setup-buildx-action@v3
29+
- name: Build Docker Image
30+
id: build
31+
uses: docker/build-push-action@v5
32+
with:
33+
context: .
34+
platforms: ${{ matrix.platform.os }}/${{ matrix.platform.arch }}
35+
outputs: docker-output
36+
cache-from: type=gha
37+
cache-to: type=gha,mode=max
38+
- run: mkdir dist
39+
- run: cp docker-output/app/telegramus dist/telegramus-${{ matrix.platform.os}}-${{ matrix.platform.arch }}
40+
- name: Release
41+
uses: softprops/action-gh-release@v1
42+
with:
43+
files: |
44+
dist/*
45+
1046
build:
1147
strategy:
1248
fail-fast: false

0 commit comments

Comments
 (0)