Skip to content

Commit

Permalink
initial github build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
pvainio committed Apr 28, 2024
1 parent 572c505 commit ed3f73f
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Main

on:
push:
tags:
- "v*.*.*"

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.22'
- name: Build arm64
env:
GOOS: linux
GOARCH: arm64
CGO_ENABLED: 0
run: go build -ldflags="-s -w" -o vallox-mqtt-arm64 .
- name: Build arm
env:
GOOS: linux
GOARCH: arm
CGO_ENABLED: 0
run: go build -ldflags="-s -w" -o vallox-mqtt-arm .
- name: Build amd64
env:
GOOS: linux
GOARCH: amd64
CGO_ENABLED: 0
run: go build -ldflags="-s -w" -o vallox-mqtt-amd64 .
- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
vallox-mqtt-arm64
vallox-mqtt-arm
vallox-mqtt-amd64
draft: true
generate_release_notes: true

0 comments on commit ed3f73f

Please sign in to comment.