Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
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
82 changes: 68 additions & 14 deletions .github/workflows/conda-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
name: Build conda package
on:
push:
branches:
- main

pull_request:

Expand All @@ -24,39 +22,47 @@ jobs:
matrix:
include:
- CONFIG: linux_64_c_compiler_version11cuda_compilernvcccuda_compiler_version11.8cxx_compiler_version11
UPLOAD_PACKAGES: True
SHORT_CONFIG: linux_64_c_compiler_version11cuda_c_h79df638478
UPLOAD_PACKAGES: False
os: ubuntu
runs_on: ['ubuntu-latest']
DOCKER_IMAGE: quay.io/condaforge/linux-anvil-cuda:11.8
- CONFIG: linux_64_c_compiler_version12cuda_compilercuda-nvcccuda_compiler_version12.0cxx_compiler_version12
UPLOAD_PACKAGES: True
SHORT_CONFIG: linux_64_c_compiler_version12cuda_c_h0d07a5e0ab
UPLOAD_PACKAGES: False
os: ubuntu
runs_on: ['ubuntu-latest']
DOCKER_IMAGE: quay.io/condaforge/linux-anvil-cos7-x86_64
- CONFIG: linux_aarch64_c_compiler_version11cuda_compilernvcccuda_compiler_version11.8cxx_compiler_version11
UPLOAD_PACKAGES: True
SHORT_CONFIG: linux_aarch64_c_compiler_version11c_h16465f209e
UPLOAD_PACKAGES: False
os: ubuntu
runs_on: ['ubuntu-latest']
DOCKER_IMAGE: quay.io/condaforge/linux-anvil-cuda:11.8
- CONFIG: linux_aarch64_c_compiler_version12cuda_compilercuda-nvcccuda_compiler_version12.0cxx_compiler_version12
UPLOAD_PACKAGES: True
SHORT_CONFIG: linux_aarch64_c_compiler_version12c_h235c88ac5f
UPLOAD_PACKAGES: False
os: ubuntu
runs_on: ['ubuntu-latest']
DOCKER_IMAGE: quay.io/condaforge/linux-anvil-cos7-x86_64
- CONFIG: osx_64_
UPLOAD_PACKAGES: True
SHORT_CONFIG: osx_64_
UPLOAD_PACKAGES: False
os: macos
runs_on: ['macos-latest']
- CONFIG: osx_arm64_
UPLOAD_PACKAGES: True
SHORT_CONFIG: osx_arm64_
UPLOAD_PACKAGES: False
os: macos
runs_on: ['macos-latest']
- CONFIG: win_64_cuda_compilercuda-nvcccuda_compiler_version12.0
UPLOAD_PACKAGES: True
SHORT_CONFIG: win_64_cuda_compilercuda-nvcccuda_c_h42eb0bda18
UPLOAD_PACKAGES: False
os: windows
runs_on: ['windows-latest']
- CONFIG: win_64_cuda_compilernvcccuda_compiler_version11.8
UPLOAD_PACKAGES: True
SHORT_CONFIG: win_64_cuda_compilernvcccuda_compil_h6e5578e1e1
UPLOAD_PACKAGES: False
os: windows
runs_on: ['windows-latest']
steps:
Expand Down Expand Up @@ -94,7 +100,6 @@ jobs:
UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }}
DOCKER_IMAGE: ${{ matrix.DOCKER_IMAGE }}
CI: github_actions
UPLOAD_ON_BRANCH: main
CONDA_FORGE_DOCKER_RUN_ARGS: "${{ matrix.CONDA_FORGE_DOCKER_RUN_ARGS }}"
BINSTAR_TOKEN: ${{ secrets.BINSTAR_TOKEN }}
shell: bash
Expand All @@ -120,7 +125,6 @@ jobs:
CONFIG: ${{ matrix.CONFIG }}
UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }}
CI: github_actions
UPLOAD_ON_BRANCH: main
BINSTAR_TOKEN: ${{ secrets.BINSTAR_TOKEN }}
shell: bash
run: |
Expand Down Expand Up @@ -155,6 +159,56 @@ jobs:
CONFIG: ${{ matrix.CONFIG }}
CI: github_actions
UPLOAD_PACKAGES: ${{ matrix.UPLOAD_PACKAGES }}
UPLOAD_ON_BRANCH: main
BINSTAR_TOKEN: ${{ secrets.BINSTAR_TOKEN }}
if: matrix.os == 'windows'
if: matrix.os == 'windows'
- name: Prepare conda build artifacts
id: prepare-artifacts
shell: bash
if: ${{ always() }}
env:
CONFIG: ${{ matrix.CONFIG }}
SHORT_CONFIG: ${{ matrix.SHORT_CONFIG }}
OS: ${{ matrix.os }}
run: |
export CI=github_actions
export CI_RUN_ID=$GITHUB_RUN_ID
export FEEDSTOCK_NAME="$(basename $GITHUB_REPOSITORY)"
export ARTIFACT_STAGING_DIR="$GITHUB_WORKSPACE"
if [ $OS == "macos" ]; then
export CONDA_BLD_DIR="${MINIFORGE_HOME:-${HOME}/miniforge3}/conda-bld"
elif [ $OS == "windows" ]; then
export CONDA_BLD_DIR="${CONDA//\\//}/conda-bld"
else
export CONDA_BLD_DIR="build_artifacts"
fi
# Archive everything in CONDA_BLD_DIR except environments
# Archive the CONDA_BLD_DIR environments only when the job fails
# Use different prefix for successful and failed build artifacts
# so random failures don't prevent rebuilds from creating artifacts.
JOB_STATUS="${{ job.status }}"
if [ $JOB_STATUS == "failure" ]; then
export BLD_ARTIFACT_PREFIX="conda_artifacts"
export ENV_ARTIFACT_PREFIX="conda_envs"
else
export BLD_ARTIFACT_PREFIX="conda_pkgs"
fi
./.scripts/create_conda_build_artifacts.sh
continue-on-error: true

- name: Store conda build artifacts
uses: actions/upload-artifact@v3
if: ${{ always() && steps.prepare-artifacts.outcome == 'success' }}
with:
name: ${{ steps.prepare-artifacts.outputs.BLD_ARTIFACT_NAME }}
path: ${{ steps.prepare-artifacts.outputs.BLD_ARTIFACT_PATH }}
retention-days: 3
continue-on-error: true

- name: Store conda build environment artifacts
uses: actions/upload-artifact@v3
if: ${{ failure() && steps.prepare-artifacts.outcome == 'success' }}
with:
name: ${{ steps.prepare-artifacts.outputs.ENV_ARTIFACT_NAME }}
path: ${{ steps.prepare-artifacts.outputs.ENV_ARTIFACT_PATH }}
retention-days: 3
continue-on-error: true
46 changes: 46 additions & 0 deletions .github/workflows/upload.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Release
on:
workflow_run:
workflows:
- Build conda package
types:
- completed

jobs:
on-success:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == "success" }}
steps:
- uses: actions/download-artifact@v4

- uses: conda-incubator/setup-miniconda@v3
with:
activate-environment: base
conda-solver: libmamba
channels:
- conda-forge
channel-priority: strict
show-channel-urls: true
miniforge-version: latest

- name: Conda environment info
shell: bash -l {0}
run: |
conda info
conda config --show
conda list --show-channel-urls

- name: Upload packages to `rapidsai-nightly
shell: bash -l {0}
run: |
# Upload packages
ls

on-failure:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == "failure" }}
steps:
- run: |
echo "Building the Conda packages failed"
exit 1

113 changes: 113 additions & 0 deletions .scripts/create_conda_build_artifacts.sh

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions .scripts/run_win_build.bat

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions conda-forge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ github:
branch_name: main
tooling_branch_name: main
github_actions:
artifact_retention_days: 7
artifact_retention_days: 3
free_disk_space: true
upload_packages: true
store_build_artifacts: true
upload_packages: false
os_version:
linux_64: cos7
linux_aarch64: cos7
Expand All @@ -28,4 +29,3 @@ provider:
osx: github_actions
win: github_actions
test: native_and_emulated
upload_on_branch: main