Skip to content

[chore][CICD] More reusable workflow organization #1

[chore][CICD] More reusable workflow organization

[chore][CICD] More reusable workflow organization #1

Workflow file for this run

name: build-package
on:
workflow_call:
inputs:
ARCH:
required: true
type: string
SYS_BINARY:
required: true
type: string
SYS_PACKAGE:
required: true
type: string
env:
GO_VERSION: 1.23.10
jobs:
cross-compile:
uses: ./.github/workflows/reusable/compile.yml

Check failure on line 21 in .github/workflows/build-package.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/build-package.yml

Invalid workflow file

invalid value workflow reference: workflows must be defined at the top level of the .github/workflows/ directory
with:
SYS_BINARY: ${{ inputs.SYS_BINARY }}
agent-bundle-linux:
strategy:
fail-fast: false
uses: ./.github/workflows/reusable/agent-bundle-linux.yml
with:
ARCH: ${{ inputs.ARCH }}
build-package:
needs: [ cross-compile, agent-bundle-linux ]
runs-on: ubuntu-24.04
steps:
- name: Check out the codebase.
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: '**/go.sum'
- name: Downloading binaries-linux_${{ inputs.ARCH }}
uses: actions/download-artifact@v4
with:
name: binaries-linux_${{ inputs.ARCH }}
path: ./bin
- uses: actions/download-artifact@v4
with:
name: agent-bundle-linux-${{ inputs.ARCH }}
path: ./dist
- name: Build ${{ inputs.SYS_PACKAGE }} ${{ inputs.ARCH }} package
run: make ${{ inputs.SYS_PACKAGE }}-package SKIP_COMPILE=true SKIP_BUNDLE=true VERSION="" ARCH="${{ inputs.ARCH }}"
- name: Uploading ${{ inputs.SYS_PACKAGE }} ${{ inputs.ARCH }} package artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.SYS_PACKAGE }}-${{ inputs.ARCH }}-package
path: ./dist/splunk-otel-collector*