Skip to content

Commit cae52b1

Browse files
committed
ci: expand build matrix and pass version args to docker build
1 parent 85f0ed1 commit cae52b1

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

.github/workflows/build-pull-request.yaml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,23 @@ jobs:
3939

4040
strategy:
4141
matrix:
42-
target: [release, develop]
42+
target: [develop]
43+
os: [ubuntu22.04, ubuntu24.04]
44+
cuda_version: [12.5.1, 13.0.2]
45+
optix_version: [7.7.0]
46+
geant4_version: [11.3.2]
47+
cmake_version: [3.22.1]
48+
49+
include:
50+
- target: release
51+
os: ubuntu24.04
52+
cuda_version: 13.0.2
4353

4454
steps:
4555
- name: Define environment variables
4656
run: |
4757
echo IMAGE_NAME=ghcr.io/$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
48-
echo IMAGE_TAG=$(echo "PR-${{ github.event.pull_request.number }}-${{ matrix.target }}") >> $GITHUB_ENV
58+
echo IMAGE_TAG=$(echo "PR-${{ github.event.pull_request.number }}-${{ matrix.cuda_version }}-${{ matrix.target }}-${{ matrix.os }}") >> $GITHUB_ENV
4959
5060
- name: Checkout code
5161
uses: actions/checkout@v4
@@ -59,6 +69,12 @@ jobs:
5969
context: .
6070
tags: ${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }}
6171
target: ${{ matrix.target }}
72+
build-args: |
73+
OS=${{ matrix.os }}
74+
CUDA_VERSION=${{ matrix.cuda_version }}
75+
OPTIX_VERSION=${{ matrix.optix_version }}
76+
GEANT4_VERSION=${{ matrix.geant4_version }}
77+
CMAKE_VERSION=${{ matrix.cmake_version }}
6278
load: true
6379
cache-from: type=local,src=/home/runner/.buildx-cache
6480
cache-to: type=local,dest=/home/runner/.buildx-cache-new,mode=max

0 commit comments

Comments
 (0)