diff --git a/buildlib/az-distro-release.yml b/buildlib/az-distro-release.yml index 8a33029fb9d..3a98c364f6e 100644 --- a/buildlib/az-distro-release.yml +++ b/buildlib/az-distro-release.yml @@ -1,6 +1,10 @@ +parameters: + arch: + demands: [] + jobs: - - job: distro_release - displayName: distro + - job: Build_${{ parameters.arch }} + displayName: Build variables: ${{ if eq(variables['Build.Reason'], 'ResourceTrigger') }}: POSTFIX: ucx-${{ replace(variables['Build.SourceBranch'], 'refs/heads/', '') }} @@ -9,43 +13,47 @@ jobs: ${{ if eq(variables['Build.Reason'], 'PullRequest') }}: POSTFIX: ucx-pr$(System.PullRequest.PullRequestNumber) - pool: - name: MLNX - demands: - - harbor_registry -equals yes - strategy: matrix: - centos7_cuda11: - build_container: centos7_cuda11 - artifact_name: $(POSTFIX)-centos7-mofed5-cuda11.tar.bz2 - centos8_cuda11: - build_container: centos8_cuda11 - artifact_name: $(POSTFIX)-centos8-mofed5-cuda11.tar.bz2 - ubuntu18_cuda11: - build_container: ubuntu18_cuda11 - artifact_name: $(POSTFIX)-ubuntu18.04-mofed5-cuda11.tar.bz2 - ubuntu20_cuda11: - build_container: ubuntu20_cuda11 - artifact_name: $(POSTFIX)-ubuntu20.04-mofed5-cuda11.tar.bz2 - ubuntu22_cuda11: - build_container: ubuntu22_cuda11 - artifact_name: $(POSTFIX)-ubuntu22.04-mofed5-cuda11.tar.bz2 - centos7_cuda12: - build_container: centos7_cuda12 - artifact_name: $(POSTFIX)-centos7-mofed5-cuda12.tar.bz2 - ubuntu18_cuda12: - build_container: ubuntu18_cuda12 - artifact_name: $(POSTFIX)-ubuntu18.04-mofed5-cuda12.tar.bz2 - ubuntu20_cuda12: - build_container: ubuntu20_cuda12 - artifact_name: $(POSTFIX)-ubuntu20.04-mofed5-cuda12.tar.bz2 - ubuntu22_cuda12: - build_container: ubuntu22_cuda12 - artifact_name: $(POSTFIX)-ubuntu22.04-mofed5-cuda12.tar.bz2 - + # common for both x86 and ARM + centos8_cuda11_${{ parameters.arch }}: + build_container: centos8_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-centos8-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + ubuntu18_cuda11_${{ parameters.arch }}: + build_container: ubuntu18_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu18.04-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + ubuntu20_cuda11_${{ parameters.arch }}: + build_container: ubuntu20_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu20.04-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + ubuntu22_cuda11_${{ parameters.arch }}: + build_container: ubuntu22_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu22.04-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + ubuntu20_cuda12_${{ parameters.arch }}: + build_container: ubuntu20_cuda12_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu20.04-mofed5-cuda12-${{ parameters.arch }}.tar.bz2 + ubuntu22_cuda12_${{ parameters.arch }}: + build_container: ubuntu22_cuda12_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu22.04-mofed5-cuda12-${{ parameters.arch }}.tar.bz2 + # x86 only + ${{ if eq(parameters.arch, 'x86_64') }}: + centos7_cuda11_${{ parameters.arch }}: + build_container: centos7_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-centos7-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + centos7_cuda12_${{ parameters.arch }}: + build_container: centos7_cuda12_${{ parameters.arch }} + artifact_name: $(POSTFIX)-centos7-mofed5-cuda12-${{ parameters.arch }}.tar.bz2 + ubuntu16_cuda11_${{ parameters.arch }}: + build_container: ubuntu16_cuda11_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu16.04-mofed5-cuda11-${{ parameters.arch }}.tar.bz2 + ubuntu18_cuda12_${{ parameters.arch }}: + build_container: ubuntu18_cuda12_${{ parameters.arch }} + artifact_name: $(POSTFIX)-ubuntu18.04-mofed5-cuda12-${{ parameters.arch }}.tar.bz2 container: $[ variables['build_container'] ] + pool: + name: MLNX + demands: ${{ parameters.demands }} + steps: - checkout: self @@ -61,7 +69,7 @@ jobs: cd pkg-build ../contrib/configure-release --with-cuda --with-java=no ../contrib/buildrpm.sh -s -t -b --noclean - cd rpm-dist/`uname -m` + cd rpm-dist/$(uname -m) tar -cjf "../../../${AZ_ARTIFACT_NAME}" *.rpm cd ../../.. tar -tjf "${AZ_ARTIFACT_NAME}" diff --git a/buildlib/az-github-draft.yml b/buildlib/az-github-draft.yml new file mode 100644 index 00000000000..d6118244387 --- /dev/null +++ b/buildlib/az-github-draft.yml @@ -0,0 +1,47 @@ +# Create an empty draft to avoid race condition in distro release + +parameters: + arch: + container: + demands: [] + +jobs: + - job: DraftRelease_${{ parameters.arch }} + displayName: Draft release ${{ parameters.arch }} + container: ${{ parameters.container }} + pool: + name: MLNX + demands: ${{ parameters.demands }} + + steps: + - checkout: self + clean: true + fetchDepth: 100 + path: "we/need/to/go/deeper" + + - bash: ./autogen.sh + displayName: Setup autotools + + - bash: | + set -eEx + # gcc --version + ./contrib/configure-release --with-java=no + ./contrib/buildrpm.sh -s -t -b + displayName: Build tarball + + - task: GithubRelease@0 + condition: eq(variables['Build.Reason'], 'IndividualCI') + displayName: Create/edit GitHub Draft Release + inputs: + githubConnection: release + repositoryName: openucx/ucx + action: edit + tag: $(Build.SourceBranchName) + isDraft: true + addChangeLog: false + releaseNotesSource: file + releaseNotesFile: NEWS + assetUploadMode: replace + assets: | + ./ucx-*.tar.gz + ./rpm-dist/ucx-*.src.rpm diff --git a/buildlib/azure-pipelines-release.yml b/buildlib/azure-pipelines-release.yml index 41863120fde..64fa303dd93 100644 --- a/buildlib/azure-pipelines-release.yml +++ b/buildlib/azure-pipelines-release.yml @@ -14,27 +14,44 @@ variables: resources: containers: - - container: centos7_cuda11 + # x86_64 + - container: centos7_cuda11_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/centos7-mofed5-cuda11:3 options: $(DOCKER_OPT_VOLUMES) - - container: centos8_cuda11 + - container: centos8_cuda11_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/centos8-mofed5-cuda11:3 - - container: ubuntu18_cuda11 + - container: ubuntu16_cuda11_x86_64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu16.04-mofed5-cuda11:3 + - container: ubuntu18_cuda11_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu18.04-mofed5-cuda11:3 - - container: ubuntu20_cuda11 + - container: ubuntu20_cuda11_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu20.04-mofed5-cuda11:3 - - container: ubuntu22_cuda11 + - container: ubuntu22_cuda11_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu22.04-mofed5-cuda11:3 - - container: centos7_cuda12 + - container: centos7_cuda12_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/centos7-mofed5-cuda12:3 options: $(DOCKER_OPT_VOLUMES) - - container: ubuntu18_cuda12 + - container: ubuntu18_cuda12_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu18.04-mofed5-cuda12:3 - - container: ubuntu20_cuda12 + - container: ubuntu20_cuda12_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu20.04-mofed5-cuda12:3 - - container: ubuntu22_cuda12 + - container: ubuntu22_cuda12_x86_64 image: rdmz-harbor.rdmz.labs.mlnx/ucx/x86_64/ubuntu22.04-mofed5-cuda12:3 + # aarch64 + - container: centos8_cuda11_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/centos8-mofed5-cuda11:3 + - container: ubuntu18_cuda11_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/ubuntu18.04-mofed5-cuda11:3 + - container: ubuntu20_cuda11_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/ubuntu20.04-mofed5-cuda11:3 + - container: ubuntu22_cuda11_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/ubuntu22.04-mofed5-cuda11:3 + - container: ubuntu20_cuda12_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/ubuntu20.04-mofed5-cuda12:3 + - container: ubuntu22_cuda12_aarch64 + image: rdmz-harbor.rdmz.labs.mlnx/ucx/aarch64/ubuntu22.04-mofed5-cuda12:3 + stages: - stage: Prepare jobs: @@ -42,7 +59,7 @@ stages: pool: name: MLNX demands: - - ucx_docker -equals yes + - ucx_docker steps: - checkout: self fetchDepth: 100 @@ -56,50 +73,23 @@ stages: name: Result displayName: Check build condition - # Create an empty draft to avoid race condition in distro releases + - stage: GitHubDraft condition: eq(dependencies.Prepare.outputs['CheckRelease.Result.Launch'], 'True') dependsOn: Prepare jobs: - - job: DraftRelease - displayName: Create draft release - container: centos7_cuda11 - pool: - name: MLNX - demands: - - ucx_docker -equals yes - steps: - - checkout: self - clean: true - fetchDepth: 100 - path: "we/need/to/go/deeper" - - - bash: ./autogen.sh - displayName: Setup autotools + - template: az-github-draft.yml + parameters: + arch: x86_64 + container: centos7_cuda11_x86_64 + demands: ucx_docker - - bash: | - set -eE - gcc --version - ./contrib/configure-release --with-java=no - ./contrib/buildrpm.sh -s -t -b - displayName: Build tarball + - template: az-github-draft.yml + parameters: + arch: aarch64 + container: centos8_cuda11_aarch64 + demands: ucx-arm64 - - task: GithubRelease@0 - condition: eq(variables['Build.Reason'], 'IndividualCI') - displayName: Create/edit GitHub Draft Release - inputs: - githubConnection: release - repositoryName: openucx/ucx - action: edit - tag: $(Build.SourceBranchName) - isDraft: true - addChangeLog: false - releaseNotesSource: file - releaseNotesFile: NEWS - assetUploadMode: replace - assets: | - ./ucx-*.tar.gz - ./rpm-dist/ucx-*.src.rpm - stage: Build displayName: Build binary packages @@ -109,9 +99,11 @@ stages: condition: eq(dependencies.Prepare.outputs['CheckRelease.Result.Launch'], 'True') jobs: - template: az-distro-release.yml - - template: jucx/jucx-publish.yml parameters: - ${{ if eq(variables['Build.Reason'], 'IndividualCI') }}: - target: publish-release - ${{ if eq(variables['Build.Reason'], 'PullRequest') }}: - target: package + arch: x86_64 + demands: ucx_docker + + - template: az-distro-release.yml + parameters: + arch: aarch64 + demands: ucx-arm64 diff --git a/buildlib/dockers/docker-compose-aarch64.yml b/buildlib/dockers/docker-compose-aarch64.yml index d1b4301e0f1..4e3c0153d3c 100644 --- a/buildlib/dockers/docker-compose-aarch64.yml +++ b/buildlib/dockers/docker-compose-aarch64.yml @@ -57,18 +57,6 @@ services: CUDA_VERSION: 11.7.0 NV_DRIVER_VERSION: 515 ARCH: aarch64 - centos7-mofed5-cuda12: - image: centos7-mofed5-cuda12:3 - build: - context: . - network: host - dockerfile: centos-release.Dockerfile - args: - MOFED_VERSION: 5.0-1.0.0.0 - MOFED_OS: rhel7.6 - CUDA_VERSION: 12.0.0 - OS_VERSION: 7 - ARCH: aarch64 ubuntu20.04-mofed5-cuda12: image: ubuntu20.04-mofed5-cuda12:3 build: diff --git a/buildlib/tools/common.sh b/buildlib/tools/common.sh index e375203ceeb..9863a89f374 100644 --- a/buildlib/tools/common.sh +++ b/buildlib/tools/common.sh @@ -11,7 +11,7 @@ MVN_MODULE="dev/mvn" XPMEM_MODULE="dev/xpmem-90a95a4" PGI_MODULE="hpc-sdk/nvhpc/21.2" GCC_MODULE="dev/gcc-10.1.0" -ARM_MODULE="arm-compiler/armcc-19.0" +ARM_MODULE="arm-compiler/armcc-22.1" INTEL_MODULE="intel/ics-19.1.1" FUSE3_MODULE="dev/fuse-3.10.5"