Private Conda and Mamba channels
Hosted accepts .conda and .tar.bz2 packages and generates repodata from the archive’s info/index.json. Publish to the intended platform directory, such as linux-64, linux-aarch64, osx-arm64, win-64, or noarch.
Create repositories
Run these Bash commands with an authenticated administrator arkactl profile and jq. Replace the endpoint and upstream address. Grant the publisher Hosted write access and the consumer read access to Group and the relevant members. For each identity, sign in and run arkactl --json tokens create --name conda-ci --expires-in-days 30 | jq -er .plaintext. Store each token directly in your secret manager.
export ARKA_URL=https://packages.example.org
hosted=$(arkactl --json repo create --name conda-hosted --type hosted --format conda | jq -er .id)
proxy=$(arkactl --json repo create --name conda-proxy --type proxy --format conda \
--upstream-url https://conda.anaconda.org/conda-forge | jq -er .id)
arkactl repo create --name conda-group --type group --format conda --member "$hosted,$proxy"
export WRITE="$ARKA_URL/repository/conda-hosted"
export READ="$ARKA_URL/repository/conda-group"Publish
Build a package with the project’s Conda pipeline. Verify name, version, build, and subdir in info/index.json. This example uses noarch.
file=acme-widget-1.2.3-py_0.conda
curl --fail-with-body -sS -H "Authorization: Bearer $ARKA_WRITE_TOKEN" \
-T "$file" "$WRITE/noarch/$file"
curl -fsS -H "Authorization: Bearer $ARKA_READ_TOKEN" "$READ/noarch/repodata.json"Authenticate and install
Conda clients that support authentication plugins can use the conda-auth HTTP Basic provider with an Arka username and token. Install the enterprise CA in the client and CI environment. The commands below assume authentication is already configured and use an empty environment path.
conda create --override-channels -c "$READ" --no-repodata-use-zst \
--prefix "$(mktemp -d)/env" 'acme-widget=1.2.3'For Micromamba, set repodata_use_zst: false in .condarc and run micromamba create --override-channels -c "$READ" -p ./env 'acme-widget=1.2.3'. Use a single channel root URL for Proxy. Group merges visible platform indexes. Set the channel order explicitly and pin the build number.
| Symptom | What to check |
|---|---|
| PackageNotFoundError | Inspect repodata.json for the target subdir and noarch. Check the build and dependency architecture. |
| repodata.json.zst returns 400 | Use uncompressed repodata.json. |
| Installed content or hash differs | Retry with a fresh MAMBA_ROOT_PREFIX or CONDA_PKGS_DIRS and compare the index’s SHA-256. |