From 86fce198a118a2a58f39f6b2b192e027066f53a3 Mon Sep 17 00:00:00 2001 From: Ryan Dale Date: Sat, 18 Nov 2023 20:22:45 -0500 Subject: [PATCH 1/5] add linux-aarch64 to local channels note that this local channel setup may not be required anymore; the test linux-aarch64 builds completed successfully even without this. But adding it in for completion's sake. --- install-and-set-up-conda.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install-and-set-up-conda.sh b/install-and-set-up-conda.sh index d8cad5e..5cdf0ca 100644 --- a/install-and-set-up-conda.sh +++ b/install-and-set-up-conda.sh @@ -87,7 +87,7 @@ if [ ${BIOCONDA_DISABLE_BUILD_PREP:=0} == 0 ]; then # Set local channel as highest priority (requires conda-build, which is # installed as a dependency of bioconda-utils) - mkdir -p "${MAMBAFORGE_INSTALLATION_DIR}/conda-bld/{noarch,linux-64,osx-64}" + mkdir -p "${MAMBAFORGE_INSTALLATION_DIR}/conda-bld/{noarch,linux-64,osx-64,linux-aarch64}" conda index "${MAMBAFORGE_INSTALLATION_DIR}/conda-bld" conda config --add channels "file://${MAMBAFORGE_INSTALLATION_DIR}/conda-bld" fi From 737c42315002760452a150aca80ab4d0a17fa323 Mon Sep 17 00:00:00 2001 From: Ryan Dale Date: Sat, 18 Nov 2023 20:23:57 -0500 Subject: [PATCH 2/5] remove MINICONDA_VER Only appears to be used in the now-deprecated bioconda-actions repo. --- common.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/common.sh b/common.sh index 47c3191..34d4892 100644 --- a/common.sh +++ b/common.sh @@ -1,4 +1,3 @@ -MINICONDA_VER=py37_4.8.3 BIOCONDA_UTILS_TAG=v2.9.0 MAMBAFORGE_VER=23.1.0-1 MAMBAFORGE_INSTALLATION_DIR="/opt/mambaforge" From 4f1d78e9586c380e714f759d02cd04942edfff3c Mon Sep 17 00:00:00 2001 From: Ryan Dale Date: Sat, 18 Nov 2023 20:26:54 -0500 Subject: [PATCH 3/5] update readme --- README.md | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a7da0ad..325556a 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,28 @@ -This repository contains common definitions for the bioconda build system, e.g., the bioconda-utils tag to use and the miniconda version. +This repository acts as a central "source of truth" which can be used by +various components of the Bioconda build system. +**`common.sh`:** contains environment variables that control versions. -- `common.sh` contains environment variables that control versions +**`install-and-set-up-conda.sh`:** +- downloads and installs conda using the Mambaforge distribution +- installs bioconda-utils dependencies +- installs the version of bioconda-utils specified in common.sh via pip install + +**`configure-conda.sh`:** ensures channels are configured correctly. + +In practice, a typical CI environment will do the following: + +1. Download the files, typically via: + + ```bash + wget https://raw.githubusercontent.com/bioconda/bioconda-common/master/{common,install-and-set-up-conda,configure-conda}.sh + ``` + +2. Run `install-and-set-up-conda.sh` (which sources `common.sh`). + +3. Use the CI platform's mechanism to cache the conda install dir (which is + configured in `common.sh`). + +4. After a cache restore, run `configure-conda.sh`. The reason for this is that + the `--system` arg for `conda config` is not supported by mamba, and so the + channel config ends up in the home directory which is not cached. From 5faa15665017a9e958e342f8fe6ce3ceaec22815 Mon Sep 17 00:00:00 2001 From: Ryan Dale Date: Sat, 18 Nov 2023 20:28:02 -0500 Subject: [PATCH 4/5] update readme --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 325556a..b13bd3b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,10 @@ +# Overview + This repository acts as a central "source of truth" which can be used by various components of the Bioconda build system. +# Components + **`common.sh`:** contains environment variables that control versions. **`install-and-set-up-conda.sh`:** @@ -10,6 +14,8 @@ various components of the Bioconda build system. **`configure-conda.sh`:** ensures channels are configured correctly. +# Typical usage + In practice, a typical CI environment will do the following: 1. Download the files, typically via: From c26746f111734f90e7493a71437ded624c1ba921 Mon Sep 17 00:00:00 2001 From: Ryan Dale Date: Sat, 18 Nov 2023 20:29:38 -0500 Subject: [PATCH 5/5] add configure-conda to test --- .github/workflows/test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index da04b52..4034354 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,3 +12,4 @@ jobs: - name: Test install bioconda-utils run: | COMMON_GIT_REF=${GITHUB_SHA} bash install-and-set-up-conda.sh + bash configure-conda.sh