Build i386 container (#3) #27
This file contains 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 and publish image | |
on: | |
workflow_dispatch: | |
inputs: | |
upstream_repository: | |
required: false | |
type: string | |
upstream_job: | |
required: false | |
type: string | |
push: | |
branches: | |
- main | |
paths: | |
- 'containers/**' | |
- '.github/workflows/containers.yml' | |
pull_request: | |
paths: | |
- 'containers/**' | |
- '.github/workflows/containers.yml' | |
schedule: | |
- cron: "0 7 * * 1" # Run once weekly | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
env: | |
BRANCH_NAME: >- | |
${{ github.event.pull_request.number && 'PR-' }}${{ github.event.pull_request.number || github.ref_name }} | |
PUBLISH_CONTAINER: 1 | |
jobs: | |
build-containers: | |
name: Build CI containers (${{ matrix.container_id }}) | |
runs-on: | |
- runs-on | |
- runner=${{ matrix.runner }} | |
- run-id=${{ github.run_id }} | |
- tag=build-containers-${{ matrix.container_id }} | |
strategy: | |
fail-fast: false | |
matrix: | |
container_id: | |
- xgb-ci.clang_tidy | |
- xgb-ci.cpu | |
- xgb-ci.gpu | |
- xgb-ci.gpu_build_r_rockylinux8 | |
- xgb-ci.gpu_build_rockylinux8 | |
- xgb-ci.gpu_build_rockylinux8_dev_ver | |
- xgb-ci.jvm | |
- xgb-ci.jvm_gpu_build | |
- xgb-ci.manylinux_2_28_x86_64 | |
- xgb-ci.manylinux2014_x86_64 | |
- xgb-ci.i386 | |
runner: [linux-amd64-cpu] | |
include: | |
- container_id: xgb-ci.aarch64 | |
runner: linux-arm64-cpu | |
- container_id: xgb-ci.manylinux2014_aarch64 | |
runner: linux-arm64-cpu | |
steps: | |
- name: Workflow trigger information | |
run: | | |
echo "Triggered by repo ${{ inputs.upstream_repository }}, job ${{ inputs.upstream_job }}" | |
if: inputs.upstream_repository != '' && inputs.upstream_job != '' | |
# Restart Docker daemon so that it recognizes the ephemeral disks | |
- run: sudo systemctl restart docker | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "true" | |
- name: Build ${{ matrix.container_id }} | |
run: bash containers/docker_build.sh ${{ matrix.container_id }} |