Skip to content

Commit

Permalink
Merge pull request #929 from svalinn/dd-ci-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gonuke authored Feb 22, 2024
2 parents ab4db53 + adcebb2 commit bdd5b79
Show file tree
Hide file tree
Showing 10 changed files with 209 additions and 146 deletions.
27 changes: 20 additions & 7 deletions .github/actions/upstream-test/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ inputs:
description: token for logging in to the GHCR
required: true
default: ''
geant_version:
geant4_version:
description: Version of Geant4
required: false
default: 11.1.2
default: off
ubuntu_version:
description: Underlying OS version
required: false
Expand All @@ -25,10 +25,10 @@ inputs:
description: Version of MOAB
required: false
default: 5.3.0
double_down:
description: Whether or not to test Double Down
double_down_version:
description: Version of Double Down
required: false
default: OFF
default: off

runs:
using: "composite"
Expand All @@ -43,11 +43,24 @@ runs:
- name: Installing Dependencies in Docker image
uses: firehed/multistage-docker-build-action@v1
with:
repository: ghcr.io/${{ github.repository_owner }}/dagmc-ci-ubuntu-${{ inputs.ubuntu_version }}-${{ inputs.compiler}}-geant4_${{ inputs.geant_version }}-hdf5_${{ inputs.hdf5_version }}-moab_${{ inputs.moab_version }}
repository: >
ghcr.io/${{ github.repository_owner }}/
dagmc-ci-ubuntu-${{ inputs.ubuntu_version }}
-${{ inputs.compiler}}
-hdf5_${{ inputs.hdf5_version}}
-moab_${{ inputs.moab_version }}
-geant4_${{ inputs.geant4_version }}
-double_down_${{ inputs.double_down_version }}
stages: base, external_deps, hdf5, moab, dagmc
server-stage: dagmc_test
quiet: false
parallel: true
tag-latest-on-default: false
dockerfile: CI/Dockerfile
build-args: COMPILER=${{ inputs.compiler }}, geant4_version=${{ inputs.geant_version }}, UBUNTU_VERSION=${{ inputs.ubuntu_version }}, HDF5_VERSION=${{ inputs.hdf5_version }}, MOAB_BRANCH=${{ inputs.moab_version }}, double_down=${{ inputs.double_down }}
build-args: >
UBUNTU_VERSION=${{ inputs.ubuntu_version }},
COMPILER=${{ inputs.compiler }},
HDF5_VERSION=${{ inputs.hdf5_version }},
MOAB_VERSION=${{ inputs.moab_version }},
GEANT4_VERSION=${{ inputs.geant4_version }},
DOUBLE_DOWN_VERSION=${{ inputs.double_down_version }}
62 changes: 44 additions & 18 deletions .github/workflows/docker_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,28 +14,29 @@ jobs:

strategy:
matrix:
ubuntu_versions : [
ubuntu_version : [
20.04,
22.04,
]
compiler : [
gcc,
clang,
]
hdf5_versions : [
hdf5_version : [
1.14.3,
]
moab_versions : [
moab_version : [
5.4.1,
5.5.1,
]
double_down : [
OFF,
]
geant_version : [
geant4_version : [
10.7.4,
11.1.2
]
double_down_version : [
off,
v1.1.0,
]

name: Installing Dependencies, Building DAGMC and running tests
steps:
Expand All @@ -58,17 +59,34 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3

- name: Configure docker image tag
run: |
image_base_tag=ghcr.io/${{ github.repository_owner }}/
image_base_tag+=dagmc-ci-ubuntu-${{ matrix.ubuntu_version }}
image_base_tag+=-${{ matrix.compiler}}
image_base_tag+=-hdf5_${{ matrix.hdf5_version}}
image_base_tag+=-moab_${{ matrix.moab_version }}
image_base_tag+=-geant4_${{ matrix.geant4_version }}
image_base_tag+=-double_down_${{ matrix.double_down_version }}
echo "image_base_tag=${image_base_tag}" >> "$GITHUB_ENV"
- name: Installing Dependencies in Docker image
uses: firehed/multistage-docker-build-action@v1
with:
repository: ghcr.io/${{ github.repository_owner }}/dagmc-ci-ubuntu-${{ matrix.ubuntu_versions }}-${{ matrix.compiler}}-geant4_${{ matrix.geant_version }}-hdf5_${{ matrix.hdf5_versions}}-moab_${{ matrix.moab_versions }}
repository: ${{ env.image_base_tag }}
stages: base, external_deps, hdf5, moab, dagmc
server-stage: dagmc_test
quiet: false
parallel: true
tag-latest-on-default: ${{ env.tag-latest-on-default }}
dockerfile: CI/Dockerfile
build-args: double_down=${{ matrix.double_down}}, geant4_version=${{ matrix.geant_version }}, COMPILER=${{ matrix.compiler }}, UBUNTU_VERSION=${{ matrix.ubuntu_versions }}, HDF5_VERSION=${{ matrix.hdf5_versions }}, MOAB_BRANCH=${{ matrix.moab_versions }}
build-args: >
UBUNTU_VERSION=${{ matrix.ubuntu_version }},
COMPILER=${{ matrix.compiler }},
HDF5_VERSION=${{ matrix.hdf5_version }},
MOAB_VERSION=${{ matrix.moab_version }},
GEANT4_VERSION=${{ matrix.geant4_version }},
DOUBLE_DOWN_VERSION=${{ matrix.double_down_version}}
push_stable_ci_img:
Expand All @@ -77,28 +95,29 @@ jobs:

strategy:
matrix:
ubuntu_versions : [
ubuntu_version : [
20.04,
22.04,
]
compiler : [
gcc,
clang,
]
hdf5_versions : [
hdf5_version : [
1.14.3,
]
moab_versions : [
moab_version : [
5.4.1,
5.5.1,
]
double_down : [
OFF,
]
geant_version : [
geant4_version : [
10.7.4,
11.1.2
]
double_down_version : [
off,
v1.1.0,
]

name: Pushing final images
steps:
Expand All @@ -110,10 +129,17 @@ jobs:
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Store image name
- name: Configure docker image tag
if: ${{ github.repository_owner == 'svalinn' }}
run: |
echo "image_base_tag=ghcr.io/${{ github.repository_owner }}/dagmc-ci-ubuntu-${{ matrix.ubuntu_versions }}-${{ matrix.compiler }}-geant4_${{ matrix.geant_version }}-hdf5_${{ matrix.hdf5_versions }}-moab_${{ matrix.moab_versions }}" >> "$GITHUB_ENV"
image_base_tag=ghcr.io/${{ github.repository_owner }}/
image_base_tag+=dagmc-ci-ubuntu-${{ matrix.ubuntu_version }}
image_base_tag+=-${{ matrix.compiler}}
image_base_tag+=-hdf5_${{ matrix.hdf5_version}}
image_base_tag+=-moab_${{ matrix.moab_version }}
image_base_tag+=-geant4_${{ matrix.geant4_version }}
image_base_tag+=-double_down_${{ matrix.double_down_version }}
echo "image_base_tag=${image_base_tag}" >> "$GITHUB_ENV"
- name: Push Image as latest img
if: ${{ github.repository_owner == 'svalinn' && github.ref == 'refs/heads/develop' }}
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/linux_upstream_test_double_down.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test against Double Down on PR merge
name: Test against Double Down development branch on PR merge

on:
# allows us to run workflows manually
Expand Down Expand Up @@ -27,6 +27,4 @@ jobs:
uses: ./.github/actions/upstream-test
with:
token: ${{ secrets.GITHUB_TOKEN }}
double_down: ON


double_down_version: develop
1 change: 0 additions & 1 deletion .github/workflows/linux_upstream_test_geant4.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,3 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
geant_version: 11.1.2

2 changes: 1 addition & 1 deletion .github/workflows/linux_upstream_test_moab.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test against MOAB master on PR merge
name: Test against MOAB development branch (master) on PR merge

on:
# allows us to run workflows manually
Expand Down
Loading

0 comments on commit bdd5b79

Please sign in to comment.