generated from dkoshkin/golang-repository-template
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (48 loc) · 1.41 KB
/
checks-macos.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# Copyright 2023 Dimitri Koshkin. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
name: build-on-macos
on:
push:
branches:
- main
pull_request:
types:
- opened
- synchronize
- reopened
branches:
- main
permissions:
contents: read
jobs:
build-and-run:
runs-on: macos-latest
steps:
- uses: ConorMacBride/install-package@v1
with:
brew: bash coreutils findutils
- name: Check out code
uses: actions/checkout@v4
- name: Install tools via asdf
uses: asdf-vm/actions/install@v3.0.2
with:
asdf_branch: v0.11.2
- name: Build
run: make SKIP_UPX=false build-snapshot
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Run binary
run: |
./dist/status-writer-action_darwin_amd64_v1/status-writer-action --version
- name: Run status-writer-action with InfluxDB
uses: ./.github/composite-actions/status-writer
# always run this step, even if previous steps fail
if: always()
with:
# select the backend to use
backend: "influxdb"
# set InfluxDB details
influxdb_token: "${{ secrets.INFLUXDB_TOKEN }}"
influxdb_url: "${{ secrets.INFLUXDB_URL }}"
influxdb_org: "${{ secrets.INFLUXDB_ORG }}"
influxdb_bucket: "${{ secrets.INFLUXDB_BUCKET }}"