Skip to content

chore(ci): update goreleaser version (#1426) #239

chore(ci): update goreleaser version (#1426)

chore(ci): update goreleaser version (#1426) #239

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
env:
GO_VERSION: 1.24
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- name: Install libpcap
run: sudo apt-get install -y libpcap-dev
- name: Checkout Source Code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Go Environment
uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- name: Download Huatuo Assets
run: |
rm -rf embedded/linux-amd64 embedded/linux-arm64
mkdir -p embedded/linux-amd64 embedded/linux-arm64
VERSION=$(curl -s "https://api.github.com/repos/ccfos/huatuo/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
echo "Downloading Huatuo $VERSION assets..."
curl -L -o embedded/linux-amd64/huatuo-$VERSION-linux-amd64.tar.gz "https://github.com/ccfos/huatuo/releases/download/$VERSION/huatuo-$VERSION-linux-amd64.tar.gz"
curl -L -o embedded/linux-arm64/huatuo-$VERSION-linux-arm64.tar.gz "https://github.com/ccfos/huatuo/releases/download/$VERSION/huatuo-$VERSION-linux-arm64.tar.gz"
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser
version: "v2.15.2"
args: release --clean --timeout 60m
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DING_TALK_TOKEN: ${{ secrets.DING_TALK_TOKEN }}