diff --git a/.github/workflows/rpm.yml b/.github/workflows/rpm.yml new file mode 100644 index 0000000000..d83b8516f3 --- /dev/null +++ b/.github/workflows/rpm.yml @@ -0,0 +1,55 @@ +name: Passenger RPM packaging tests + +env: + ENTERPRISE: 0 + +on: + push: + branches: + - 'stable-*' + - 'feature/*' + pull_request: + branches: + - 'stable-*' + - 'feature/*' + +jobs: + define-matrix: + runs-on: ubuntu-latest + outputs: + distros: ${{ steps.distros.outputs.distros }} + steps: + - uses: actions/checkout@v4 + with: + submodules: true + - name: Define Distros + id: distros + run: echo "distros=[$(awk -F= '/DEFAULT_DISTROS/{print $2}' packaging/rpm/internal/lib/distro_info.sh | sed -e 's/ /", "/g')]" >> "$GITHUB_OUTPUT" + + test: + name: "Test ${{ matrix.distro }} ${{ matrix.arch }} packages" + needs: define-matrix + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + distro: ${{ fromJSON(needs.define-matrix.outputs.distros) }} + arch: + - x86_64 + #- aarch64 + env: + WORKSPACE: ${{ github.workspace }} + ARCHITECTURE: ${{ matrix.arch }} + CACHE_DIR: ${{ github.workspace }}/cache/rpm-test/${{ matrix.distro }}-${{ matrix.arch }} + DISTRIBUTION: ${{ matrix.distro }} + steps: + - uses: actions/checkout@v4 + with: + submodules: true + - uses: docker/setup-qemu-action@v3 + - uses: docker/setup-buildx-action@v3 + - run: ./dev/ci/tests/rpm/run + - uses: actions/upload-artifact@v4 + with: + name: rpm-${{ matrix.distro }}-${{ matrix.arch }} + path: 'output/${{ matrix.distro }}/*' diff --git a/dev/ci/tests/rpm/run b/dev/ci/tests/rpm/run index 1d96dd2cb5..b881cdc96a 100755 --- a/dev/ci/tests/rpm/run +++ b/dev/ci/tests/rpm/run @@ -59,5 +59,6 @@ run ./test \ -d "$WORKSPACE/output/$DISTRIBUTION" \ -c "$CACHE_DIR" \ -x "$TEST_DISTRO_NAME" \ + -a "$ARCHITECTURE" \ -j \ $EXTRA_TEST_PARAMS diff --git a/packaging/rpm b/packaging/rpm index 7028e681a7..0f3f49bd32 160000 --- a/packaging/rpm +++ b/packaging/rpm @@ -1 +1 @@ -Subproject commit 7028e681a7eeb357430f61e77895fe74169d9f9d +Subproject commit 0f3f49bd32134f52295e615c2294a45bf4bb817f