Skip to content

Hotfix buffer issue (#60) #111

Hotfix buffer issue (#60)

Hotfix buffer issue (#60) #111

Workflow file for this run

name: Threadfin Beta Build
on:
push:
branches:
- beta
permissions:
contents: write
jobs:
buildBinaries:
name: Build and release binaries
runs-on: ubuntu-latest
outputs:
new_version: ${{ steps.set-build-number.outputs.new_version }}
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4
with:
ref: beta
- name: Set build number
id: set-build-number
run: |
bash ${GITHUB_WORKSPACE}/Utility/set_build_number.sh ${{ vars.BUILD_NUMBER }}
- name: Update repo variable
run: |
bash ${GITHUB_WORKSPACE}/Utility/update_build_number_variable.sh ${{ secrets.API_TOKEN }} ${{ github.repository }} ${{ env.NEW_BUILD }}
- name: Set up and Build
uses: actions/setup-go@v5
with:
go-version: 1.23
id: go
- name: Build binaries
run: |
go mod tidy && go mod vendor
bash ${GITHUB_WORKSPACE}/Utility/create_binaries.sh beta
- name: Create a Release
uses: softprops/action-gh-release@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
prerelease: true
name: v${{ env.NEW_VERSION }} (Beta)
tag_name: v${{ env.NEW_VERSION }}-beta
files: dist/*
buildDockerImages:
name: Build and push Docker images
runs-on: ubuntu-latest
needs: buildBinaries
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set NEW_VERSION
run: echo "NEW_VERSION=${{ needs.buildBinaries.outputs.new_version }}" >> $GITHUB_ENV
shell: bash
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Docker Build and Push
uses: docker/build-push-action@v6
with:
context: .
build-args: |
BRANCH=beta
VERSION=${{ env.NEW_VERSION }}
push: true
no-cache: true
platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v8
tags: |
mgoerentz/threadfin:latest-beta
mgoerentz/threadfin:v${{ env.NEW_VERSION }}-beta