Skip to content

Bump the github-actions group across 1 directory with 2 updates (#11) #8

Bump the github-actions group across 1 directory with 2 updates (#11)

Bump the github-actions group across 1 directory with 2 updates (#11) #8

# Build and upload provider artifact on merge to trunk
name: Build Artifact
on:
push:
branches:
- trunk
permissions:
contents: read
jobs:
build:
name: Build Provider
runs-on: ubuntu-latest
timeout-minutes: 10
strategy:
matrix:
include:
- goos: linux
goarch: amd64
- goos: linux
goarch: arm64
- goos: darwin
goarch: amd64
- goos: darwin
goarch: arm64
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0
with:
go-version-file: 'go.mod'
cache: true
- name: Build provider
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
CGO_ENABLED: '0'
run: |
go build -trimpath -ldflags="-s -w" -o terraform-provider-spiceai_${{ matrix.goos }}_${{ matrix.goarch }} .
- name: Upload artifact
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: terraform-provider-spiceai_${{ matrix.goos }}_${{ matrix.goarch }}
path: terraform-provider-spiceai_${{ matrix.goos }}_${{ matrix.goarch }}
retention-days: 90
# Combine all platform artifacts into a single artifact for convenience
combine:
name: Combine Artifacts
needs: build
runs-on: ubuntu-latest
steps:
- name: Download all artifacts
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
with:
path: artifacts
pattern: terraform-provider-spiceai_*
merge-multiple: true
- name: Upload combined artifact
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: terraform-provider-spiceai
path: artifacts/
retention-days: 90