From 489ac0cc90bec662b53d8bc3cae93a51a35e1e77 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Thu, 1 Feb 2024 17:17:12 +0100 Subject: [PATCH 1/3] Trigger packages action on subset for PRs This patch set's PR events to only test against amd64, and full multiarch matrix after merge event Signed-off-by: Evan Lezar --- .github/workflows/packages.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/packages.yaml b/.github/workflows/packages.yaml index 6475cf2c..81c7e0be 100644 --- a/.github/workflows/packages.yaml +++ b/.github/workflows/packages.yaml @@ -16,6 +16,13 @@ name: image on: + pull_request: + types: + - opened + - synchronize + branches: + - main + - release-* push: branches: - main @@ -33,6 +40,17 @@ jobs: - centos7-aarch64 - centos7-x86_64 - centos8-ppc64le + ispr: + - ${{github.event_name == 'pull_request'}} + exclude: + - ispr: true + package: ubuntu18.04-arm64 + - ispr: true + package: ubuntu18.04-ppc64le + - ispr: true + package: centos7-aarch64 + - ispr: true + package: centos8-ppc64le fail-fast: false steps: - uses: actions/checkout@v4 From e7cba77f06434abccc2b2ae492e9ea93a7fcc757 Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Thu, 1 Feb 2024 17:30:06 +0100 Subject: [PATCH 2/3] Add git describe action Signed-off-by: Evan Lezar --- .github/workflows/packages.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/packages.yaml b/.github/workflows/packages.yaml index 81c7e0be..dc296dbc 100644 --- a/.github/workflows/packages.yaml +++ b/.github/workflows/packages.yaml @@ -55,11 +55,17 @@ jobs: steps: - uses: actions/checkout@v4 name: Check out code + - name: Git describe + id: ghd + uses: proudust/gh-describe@v1 - name: Set up QEMU uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 - name: build ${{ matrix.package }} packages + env: + GIT_TAG: ${{ steps.ghd.outputs.describe }} + GIT_COMMIT: ${{ steps.ghd.outputs.sha }} run: | sudo apt-get install -y coreutils build-essential sed git bash make echo "Building packages" From badbe8a2e28cd1832509e32471e0f9e834b596ad Mon Sep 17 00:00:00 2001 From: Evan Lezar Date: Thu, 1 Feb 2024 17:40:04 +0100 Subject: [PATCH 3/3] fix Signed-off-by: Evan Lezar --- .github/workflows/packages.yaml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/packages.yaml b/.github/workflows/packages.yaml index dc296dbc..17d95931 100644 --- a/.github/workflows/packages.yaml +++ b/.github/workflows/packages.yaml @@ -55,17 +55,14 @@ jobs: steps: - uses: actions/checkout@v4 name: Check out code - - name: Git describe - id: ghd - uses: proudust/gh-describe@v1 + with: + fetch-tags: true + fetch-depth: 1024 - name: Set up QEMU uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 - name: build ${{ matrix.package }} packages - env: - GIT_TAG: ${{ steps.ghd.outputs.describe }} - GIT_COMMIT: ${{ steps.ghd.outputs.sha }} run: | sudo apt-get install -y coreutils build-essential sed git bash make echo "Building packages"