Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: split ci into atomic workflows #3266

Open
wants to merge 24 commits into
base: develop
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
wip:
Lionel Untereiner committed Oct 2, 2024
commit 99d3a78332658bb3239059529ec306bc0d9d5dbf
2 changes: 0 additions & 2 deletions .github/workflows/compliance.yml
Original file line number Diff line number Diff line change
@@ -190,6 +190,4 @@ jobs:
- get_docker_image_tag
- check_that_all_jobs_succeeded
uses: ./.github/workflows/cpu_builds.yml
with:
DOCKER_IMAGE_TAG: ${{ needs.get_docker_image_tag.outputs.DOCKER_IMAGE_TAG }}
secrets: inherit
41 changes: 25 additions & 16 deletions .github/workflows/cpu_builds.yml
Original file line number Diff line number Diff line change
@@ -1,34 +1,43 @@
name: CPU builds

on:
# pull_request: # Run workflow on PRs to the develop branch with changes on *.hpp or *.cpp files when PR is opened, synchronized, reopented and ready fo review
# branches:
# - develop
# paths:
# - '**.hpp'
# - '**.cpp'
# types:
# - opened
# - synchronize
# - reopened
# - ready_for_review
# Allow this workflow to be called by the main workflow.
workflow_call:
inputs:
DOCKER_IMAGE_TAG:
required: true
type: string
push: # Run workflow on push to the develop branch.
branches:
- develop
workflow_dispatch: # Workflow can be run manually


jobs:
get_docker_image_tag:
if: "${{ github.event.label.name == 'ci: run integrated tests' }}"
# Everywhere in this workflow, we use the most recent ubuntu distribution available in Github Actions
# to ensure maximum support of google cloud's sdk.
runs-on: ubuntu-22.04
outputs:
DOCKER_IMAGE_TAG: ${{ steps.extract_docker_image_tag.outputs.DOCKER_IMAGE_TAG }}
steps:
# The TPL tag is contained in the codespaces configuration to avoid duplications.
- name: Checkout .devcontainer/devcontainer.json
uses: actions/checkout@v4.1.7
with:
sparse-checkout: |
.devcontainer/devcontainer.json
sparse-checkout-cone-mode: false
submodules: false
lfs: false
fetch-depth: 1
- name: Extract docker image tag
id: extract_docker_image_tag
run: |
echo "DOCKER_IMAGE_TAG=$(jq '.build.args.GEOS_TPL_TAG' -r .devcontainer/devcontainer.json)" >> "$GITHUB_OUTPUT"
# Matrix containing all the CPU build.
# Those are quite fast and can efficiently benefit from the `sccache' tool to make them even faster.
cpu_builds:
name: ${{ matrix.name }}
needs:
- get_docker_image_tag
strategy:
# In-progress jobs will not be cancelled if there is a failure
fail-fast : false
@@ -76,7 +85,7 @@ jobs:
uses: ./.github/workflows/build_and_test.yml
with:
CMAKE_BUILD_TYPE: ${{ matrix.CMAKE_BUILD_TYPE }}
DOCKER_IMAGE_TAG: ${{ inputs.DOCKER_IMAGE_TAG }}
DOCKER_IMAGE_TAG: ${{ needs.get_docker_image_tag.outputs.DOCKER_IMAGE_TAG }}
DOCKER_REPOSITORY: ${{ matrix.DOCKER_REPOSITORY }}
ENABLE_HYPRE: ${{ matrix.ENABLE_HYPRE }}
ENABLE_TRILINOS: ${{ matrix.ENABLE_TRILINOS }}
1 change: 1 addition & 0 deletions .github/workflows/gpu_builds.yml
Original file line number Diff line number Diff line change
@@ -130,6 +130,7 @@ jobs:
secrets: inherit

remove_label:
if: always()
needs:
- cuda_builds
runs-on: ubuntu-22.04
1 change: 1 addition & 0 deletions .github/workflows/integrated_tests.yml
Original file line number Diff line number Diff line change
@@ -57,6 +57,7 @@ jobs:
LOCAL_BASELINE_DIR: /data/GEOS/baselines

remove_label:
if: always()
needs:
- run_integrated_tests
runs-on: ubuntu-22.04