Build RPM Packages #7
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 RPM Packages" | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| mcpp_version: | |
| description: "The MCPP version to build" | |
| required: false | |
| jobs: | |
| build: | |
| name: "Build for ${{ matrix.distribution }}-${{ matrix.arch }}" | |
| runs-on: ${{ matrix.arch == 'aarch64' && 'ubuntu-24.04-arm' || 'ubuntu-24.04' }} | |
| strategy: | |
| matrix: | |
| include: | |
| - distribution: rhel9 | |
| arch: x86_64 | |
| image: ghcr.io/zeroc-ice/mcpp-rpm-package-builder-x86_64-rhel9:latest | |
| - distribution: rhel9 | |
| arch: aarch64 | |
| image: ghcr.io/zeroc-ice/mcpp-rpm-package-builder-aarch64-rhel9:latest | |
| - distribution: rhel10 | |
| arch: x86_64 | |
| image: ghcr.io/zeroc-ice/mcpp-rpm-package-builder-x86_64-rhel10:latest | |
| - distribution: rhel10 | |
| arch: aarch64 | |
| image: ghcr.io/zeroc-ice/mcpp-rpm-package-builder-aarch64-rhel10:latest | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v4 | |
| with: | |
| path: mcpp | |
| - name: Build RPM Packages | |
| run: | | |
| docker run --rm \ | |
| -v "$GITHUB_WORKSPACE:/workspace" \ | |
| -e MCPP_VERSION="${{ inputs.mcpp_version }}" \ | |
| -e GIT_TAG="${{ github.ref_name }}" \ | |
| -e BUILD_ARCH="${{ matrix.arch }}" \ | |
| ${{matrix.image}} \ | |
| /workspace/mcpp/packaging/rpm/build-package.sh | |
| - name: Upload Artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: rpm-packages-${{ matrix.distribution }}-${{ matrix.arch }} | |
| path: | | |
| build/RPMS/* |