-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (50 loc) · 1.3 KB
/
go.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
# This workflow will build a golang project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
name: Go
on:
push:
tags:
- "v*.*.*"
pull_request:
branches: [ "main" ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Update apt cache
run: sudo apt-get update
- name: Install ffmpeg
run: sudo apt-get install -y ffmpeg
- name: Install unzip
run: sudo apt-get install -y unzip
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.23.1'
- name: Build Plugins
run: bash -c ./scripts/compile_plugins.sh
env:
ENV: PRODUCTION
- name: Build
run: go build --trimpath -o ./fedai-linux-amd64 main.go
env:
GOOS: linux
GOARCH: amd64
- name: Create zip(plugins)
run: cd pl && zip -r plugins.zip . && mv plugins.zip ../
- name: Create Release
uses: softprops/action-gh-release@v2
with:
files: |
fedai-linux-amd64
plugins.zip
- name: 'Upload Artifacts'
uses: actions/upload-artifact@v4
with:
name: fedai
path: |
./fedai-linux-amd64
./plugins.zip
retention-days: 5