Skip to content

#49 - Read in config #85

#49 - Read in config

#49 - Read in config #85

Workflow file for this run

---
name: Build
on:
pull_request:
branches:
- main
- devel
workflow_dispatch:
jobs:
golang:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version: '^1.22.2'
- run: make promu
- run: promu crossbuild -v
- name: Store binaries
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
with:
name: build
path: .build
if-no-files-found: error
include-hidden-files: true
- name: Test binary
run: .build/linux-amd64/twitch_exporter --help
docker:
needs: golang
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Download binaries artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: build
path: .build
# See https://github.com/actions/upload-artifact/issues/38
- name: Fix permission on binaries artifacts
run: find . -type f -name 'twitch_exporter' -exec chmod +x {} +
- run: make docker
- run: docker run docker.io/damoun/twitch-exporter-linux-amd64:HEAD --help