-
Notifications
You must be signed in to change notification settings - Fork 6
CI: Split up our monolithic build workflow #150
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
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
4fe74d5
CI: Move build AIS for Nvidia to a separate workflow.
riley-dixon 71344f8
CI: Move disabled Nvidia test job to Nvidia build workflow.
riley-dixon 7c0c663
CI: Move AIS System tests into separate workflow.
riley-dixon b9e132c
CI: Add an EnvVar to track which package format is being used.
riley-dixon 8eb87cf
CI: Add an EnvVar to track which package manager is being used.
riley-dixon 3177da9
CI: Add flag to control build artifact uploads
riley-dixon dfea800
CI: Parameterize the CXX compiler used in the build workflow
riley-dixon b573074
CI: Run code coverage only on amdclang++ on Ubuntu
riley-dixon f0b98b8
CI: Consolidate AMD build steps to single workflow.
riley-dixon 34068fa
Formatting
riley-dixon b21dd79
CI: Refactor how ci_image gets set.
riley-dixon 26122ab
CI: Refactor ais_ci conditional on build_AIS_CI_image
riley-dixon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,107 @@ | ||
| name: build_ais_nvidia | ||
| run-name: Build AIS for Nvidia platforms | ||
| env: | ||
| AIS_MOUNT_PATH: /mnt/ais/ext4 | ||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| ci_image: | ||
| required: true | ||
| type: string | ||
| platform: | ||
| required: true | ||
| type: string | ||
| permissions: | ||
| contents: read | ||
| packages: read | ||
| jobs: | ||
| compile_on_NVIDIA: | ||
| runs-on: [ubuntu-24.04] | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| supported_compilers: | ||
| - g++ | ||
| - clang++ | ||
| steps: | ||
| - name: Set early AIS CI environment variables | ||
| run: | | ||
| echo "AIS_PR_NUMBER=$(echo ${{ github.ref }} | sed 's|[^0-9]||g')" >> "${GITHUB_ENV}" | ||
| echo "AIS_SAFE_COMPILER_NAME=$(echo ${{ matrix.supported_compilers }} | sed 's|[\+]|plus|g')" >> "${GITHUB_ENV}" | ||
|
|
||
| - name: Set AIS CI container name | ||
| run: | | ||
| echo "AIS_CONTAINER_NAME=${AIS_PR_NUMBER}_${{ github.job }}_${{ inputs.platform }}_${AIS_SAFE_COMPILER_NAME}" >> "${GITHUB_ENV}" | ||
|
|
||
| - name: Fetching code repository... | ||
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 | ||
| with: | ||
| path: hipFile | ||
| - name: Authenticating to GitHub Container Registry | ||
| uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef #v3.6.0 | ||
| with: | ||
| registry: ghcr.io | ||
| username: ${{ github.actor }} | ||
| password: ${{ secrets.GITHUB_TOKEN }} | ||
| # Detach the container and run separate commands to it. | ||
| # Thus we can make separate explicit steps in the Github CI | ||
| # as if we were able to parameterize the container image in the first place. | ||
| - name: Starting Docker Container | ||
| run: | | ||
| docker run \ | ||
| -dt \ | ||
| --rm \ | ||
| --pull always \ | ||
| -v ${GITHUB_WORKSPACE}:/mnt/ais:ro \ | ||
| -v ${{ env.AIS_MOUNT_PATH }}:/mnt/ais-fs \ | ||
|
|
||
| --name ${AIS_CONTAINER_NAME} \ | ||
| ${{ inputs.ci_image }} | ||
|
|
||
| - name: Make copy of the code repository and create build directories | ||
| run: | | ||
| docker exec \ | ||
| -t \ | ||
| ${AIS_CONTAINER_NAME} \ | ||
| /bin/bash -c ' | ||
| cp -R /mnt/ais /ais | ||
| mkdir /ais/hipFile/build | ||
| ' | ||
| - name: Generate build files for hipFile targeting the NVIDIA platform (${{ matrix.supported_compilers }}) | ||
| run: | | ||
| docker exec \ | ||
| -t \ | ||
| -w /ais/hipFile/build \ | ||
| ${AIS_CONTAINER_NAME} \ | ||
| /bin/bash -c ' | ||
| cmake \ | ||
| -DCMAKE_CXX_COMPILER=${{ matrix.supported_compilers }} \ | ||
|
|
||
| -DCMAKE_CXX_FLAGS="-Werror" \ | ||
| -DCMAKE_HIP_PLATFORM=nvidia \ | ||
| -DAIS_BUILD_DOCS=ON \ | ||
| .. | ||
| ' | ||
| - name: Build hipFile for the NVIDIA platform (${{ matrix.supported_compilers }}) | ||
| run: | | ||
| docker exec \ | ||
| -t \ | ||
| -w /ais/hipFile/build \ | ||
| ${AIS_CONTAINER_NAME} \ | ||
| /bin/bash -c ' | ||
| cmake --build . --parallel | ||
| ' | ||
| - name: Clean CMake build directories | ||
| run: | | ||
| docker exec \ | ||
| -t \ | ||
| -w /ais/hipFile \ | ||
| ${AIS_CONTAINER_NAME} \ | ||
| /bin/bash -c ' | ||
| rm -rf build/* | ||
| ' | ||
| - name: Cleanup & Stop the Docker container | ||
| if: ${{ always() }} | ||
| run: | | ||
| docker stop ${AIS_CONTAINER_NAME} | ||
| ### Disable until NVIDIA runners come back | ||
| # Run_hipFile_NVIDIA: | ||
| # uses: ./.github/workflows/hipfile-nvidia.yml | ||
| # needs: build_AIS_image | ||
| # with: | ||
| # platform: ${{inputs.platform}} | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.