Skip to content

Update go.mod and github build workflow actions #97

Update go.mod and github build workflow actions

Update go.mod and github build workflow actions #97

Workflow file for this run

name: build
on:
push:
pull_request:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: ubuntu-22.04
arch: amd64
build: true
- os: ubuntu-22.04-arm
arch: arm64
build: true
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Set up golang
uses: actions/setup-go@v5
with:
go-version: 1.23
- name: Install build dependencies
run: |
sudo apt-get update
sudo apt-get install golang make
- name: Make machine binaries
run: |
make
mv bin/machine bin/machine-linux-${{matrix.arch}}
mv bin/machined bin/machined-linux-${{matrix.arch}}
ls -al bin/
- name: Test machine unittests
run: |
make test
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: machine-linux-${{matrix.arch}}
path: bin/machine*-linux-${{matrix.arch}}
if-no-files-found: error
- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
name: machine-linux-${{matrix.arch}}
path: bin/machine*-linux-${{matrix.arch}}