-
Notifications
You must be signed in to change notification settings - Fork 0
71 lines (57 loc) · 2.11 KB
/
release.yml
File metadata and controls
71 lines (57 loc) · 2.11 KB
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
61
62
63
64
65
66
67
68
69
70
71
name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
build-and-release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.21'
- name: Get version from tag
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Build binaries
run: |
# Build for Linux AMD64
make clean
make build
mkdir -p release/tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64
cp tailproxy libtailproxy.so release/tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64/
cp README.md release/tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64/
cd release
tar czf tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64.tar.gz tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64
cd ..
- name: Generate checksums
run: |
cd release
sha256sum tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64.tar.gz > checksums.txt
cat checksums.txt
- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: |
release/tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64.tar.gz
release/checksums.txt
body: |
## TailProxy ${{ steps.get_version.outputs.VERSION }}
### Installation
Download the archive for your platform and extract it:
```bash
tar xzf tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64.tar.gz
cd tailproxy-${{ steps.get_version.outputs.VERSION }}-linux-amd64
sudo cp tailproxy libtailproxy.so /usr/local/bin/
```
### Checksums
See `checksums.txt` for SHA256 checksums of all release artifacts.
draft: false
prerelease: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}