Configuring conda to use your local on-site AEN repository

You can configure AEN to use a local on-site Anaconda Repository server instead of Anaconda.org.

To configure AEN to use a local on-site Repository, you must:

  1. Edit condarc on the compute node.
  2. Configure the Anaconda client.

Editing condarc on the compute node

NOTE: If there are channels that you haven’t mirrored, you must remove them from the configuration.

Edit the file .condarc to match the following:

#/opt/wakari/anaconda/.condarc
channels:
    - defaults

create_default_packages:
    - anaconda-client
    - ipykernel

# Default channels is needed for when users override the system .condarc
# with ~/.condarc.  This ensures that "defaults" maps to your Anaconda Repository and not
# repo.anaconda.com
default_channels:
    - http://<your Anaconda Repository name>:8080/conda/anaconda
    - http://<your Anaconda Repository name>:8080/conda/wakari
    - http://<your Anaconda Repository name>:8080/conda/r-channel

# Note:  You must add the "conda" subdirectory to the end
channel_alias: http://<your Anaconda Repository name:8080/conda

NOTE: Replace <your Anaconda Repository name> with the actual name or IP address of your local Anaconda Repository installation.

Configuring the Anaconda client

Anaconda client lets users work with Repository from the command-line—including searching for packages, logging in, uploading packages, and more.

To set the default configuration of anaconda-client for all users on your compute node:

sudo /opt/wakari/anaconda/bin/anaconda config --set url http://<your Anaconda Repository>:8080/api -s

NOTE: Sudo is required because the configuration file is written to the root file system: /etc/xdg/binstar/config.yaml.

NOTE: Replace <your Anaconda Repository> with the actual name or IP address of your local Anaconda Repository installation.

What’s next

Review the optional configuration tasks to see if any apply to your system.