match workflow triggers #197
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: build-artifacts.yml | |
| permissions: | |
| contents: read | |
| id-token: write | |
| attestations: write | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| # yamllint disable-line rule:quoted-strings | |
| - "dev/*" | |
| # yamllint disable-line rule:quoted-strings | |
| - "hotfix/*" | |
| # yamllint disable-line rule:quoted-strings | |
| - "main" | |
| # yamllint disable-line rule:quoted-strings | |
| - "master" | |
| tags: | |
| - "*" | |
| jobs: | |
| build-artifacts: | |
| strategy: | |
| matrix: | |
| distro: | |
| - el8 | |
| - el9 | |
| - el10 | |
| - amzn2023 | |
| - debian12 | |
| - debian13 | |
| - ubuntu20.04 | |
| - ubuntu22.04 | |
| - ubuntu24.04 | |
| host: | |
| - ubuntu-24.04 | |
| - ubuntu-24.04-arm | |
| uses: aerospike/shared-workflows/.github/workflows/[email protected] | |
| with: | |
| runs-on: ${{ matrix.host }} | |
| jf-project: database | |
| jf-build-id: ${{ github.run_number }} | |
| # this is the default behaviour so we can leave it out but if it is wanted to be explicit | |
| # we need to use the ref not the ref_name in github actions. The ref_name is the short name and so not a valid ref. | |
| # gh-source-ref: ${{ github.ref }} | |
| build-script: local/.github/packaging/project/gha-main.sh "${{ matrix.distro }}" | |
| gh-artifact-directory: dist | |
| gh-artifact-name: unsigned-artifacts-${{ matrix.distro }}-${{ matrix.host }} | |
| gh-retention-days: 1 | |
| dry-run: false | |
| oidc-provider-name: database-gh-aerospike | |
| oidc-audience: database-gh-aerospike | |
| jf-build-name: asconfig | |
| sign-artifacts: | |
| strategy: | |
| matrix: | |
| distro: | |
| - el8 | |
| - el9 | |
| - el10 | |
| - amzn2023 | |
| - debian12 | |
| - debian13 | |
| - ubuntu20.04 | |
| - ubuntu22.04 | |
| - ubuntu24.04 | |
| host: | |
| - ubuntu-24.04 | |
| - ubuntu-24.04-arm | |
| needs: build-artifacts | |
| uses: aerospike/shared-workflows/.github/workflows/[email protected] | |
| with: | |
| gh-artifact-name: signed-artifacts-${{ matrix.distro }}-${{ matrix.host }} | |
| gh-unsigned-artifacts: unsigned-artifacts-${{ matrix.distro }}-${{ matrix.host }} | |
| secrets: | |
| gpg-private-key: ${{ secrets.GPG_SECRET_KEY }} | |
| gpg-public-key: ${{ secrets.GPG_PUBLIC_KEY }} | |
| gpg-key-pass: ${{ secrets.GPG_PASS }} | |
| upload-artifacts: | |
| strategy: | |
| matrix: | |
| distro: | |
| - el8 | |
| - el9 | |
| - el10 | |
| - amzn2023 | |
| - debian12 | |
| - debian13 | |
| - ubuntu20.04 | |
| - ubuntu22.04 | |
| - ubuntu24.04 | |
| host: | |
| - ubuntu-24.04 | |
| - ubuntu-24.04-arm | |
| needs: sign-artifacts | |
| uses: aerospike/shared-workflows/.github/workflows/[email protected] | |
| with: | |
| jf-project: database | |
| jf-build-name: asconfig | |
| version: ${{ github.ref_name }} | |
| oidc-provider-name: database-gh-aerospike | |
| oidc-audience: database-gh-aerospike | |
| gh-artifact-name: signed-artifacts-${{ matrix.distro }}-${{ matrix.host }} | |
| gh-retention-days: 1 | |
| dry-run: false | |
| jf-build-id: ${{ github.run_number }} | |
| jf-metadata-build-id: ${{ github.run_number }}-metadata | |
| test-install-from-jfrog-and-execute: | |
| strategy: | |
| matrix: | |
| distro: | |
| - el8 | |
| - el9 | |
| - el10 | |
| - amzn2023 | |
| - debian12 | |
| - debian13 | |
| - ubuntu20.04 | |
| - ubuntu22.04 | |
| - ubuntu24.04 | |
| host: | |
| - ubuntu-24.04 | |
| - ubuntu-24.04-arm | |
| needs: upload-artifacts | |
| env: | |
| JFROG_CLI_BUILD_NAME: ${{ inputs.jf-build-name || github.workflow }} | |
| JFROG_CLI_LOG_LEVEL: INFO | |
| runs-on: ${{ matrix.host }} | |
| permissions: | |
| contents: read | |
| packages: write | |
| attestations: write | |
| id-token: write | |
| steps: | |
| - name: Install JFrog CLI | |
| id: jf | |
| uses: jfrog/setup-jfrog-cli@5b06f730cc5a6f55d78b30753f8583454b08c0aa # v4.8.1 | |
| env: | |
| JF_URL: https://artifact.aerospike.io | |
| JF_PROJECT: database | |
| with: | |
| oidc-provider-name: database-gh-aerospike | |
| oidc-audience: database-gh-aerospike | |
| - name: Checkout | |
| uses: actions/checkout@v5 | |
| with: | |
| ref: ${{ github.ref }} | |
| submodules: recursive | |
| - name: Run test cases | |
| env: | |
| JF_TOKEN: ${{ steps.jf.outputs.oidc-token }} | |
| JF_USERNAME: ${{ steps.jf.outputs.oidc-user }} | |
| run: .github/packaging/project/test/gha-test-main.sh ${{ matrix.distro }} ${{ github.event.repository.name }} | |