Skip to content

Commit

Permalink
add rpms to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
CamJN committed Sep 7, 2024
1 parent ea50c20 commit 132b8e2
Show file tree
Hide file tree
Showing 6 changed files with 77 additions and 8 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,13 @@ env:

on:
push:
branches: [ 'stable-*' ]
branches:
- 'stable-*'
# - 'feature/*'
pull_request:
branches: [ 'stable-*' ]
branches:
- 'stable-*'
# - 'feature/*'

jobs:
build_linux:
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,13 @@ env:

on:
push:
branches: [ 'stable-*', 'feature/*' ]
branches:
- 'stable-*'
# - 'feature/*'
pull_request:
branches: [ 'stable-*', 'feature/*' ]
branches:
- 'stable-*'
# - 'feature/*'

jobs:
define-matrix:
Expand All @@ -32,7 +36,7 @@ jobs:
distro: ${{ fromJSON(needs.define-matrix.outputs.distros) }}
arch:
- amd64
- arm64
#- arm64
env:
WORKSPACE: ${{ github.workspace }}
ARCHITECTURE: ${{ matrix.arch }}
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,13 @@ env:

on:
push:
branches: [ 'stable-*' ]
branches:
- 'stable-*'
# - 'feature/*'
pull_request:
branches: [ 'stable-*' ]
branches:
- 'stable-*'
# - 'feature/*'

jobs:
cxx:
Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/rpm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
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
- run: ls -R output
- uses: actions/upload-artifact@v4
with:
name: rpm-${{ matrix.distro }}-${{ matrix.arch }}
path: 'output/${{ matrix.distro }}/*'
1 change: 1 addition & 0 deletions dev/ci/tests/rpm/run
Original file line number Diff line number Diff line change
Expand Up @@ -59,5 +59,6 @@ run ./test \
-d "$WORKSPACE/output/$DISTRIBUTION" \
-c "$CACHE_DIR" \
-x "$TEST_DISTRO_NAME" \
-a "$ARCHITECTURE" \
-j \
$EXTRA_TEST_PARAMS
2 changes: 1 addition & 1 deletion packaging/rpm
Submodule rpm updated 2 files
+0 −1 internal/test/test.sh
+28 −10 test

0 comments on commit 132b8e2

Please sign in to comment.