Can I create a local repository using the open-source version of Anaconda?

Hi Guys,

I would like to create my own repository to share packages to clients that don’t have internet access, do you guys know if I will be able to do that using the open-source version? If yes, is there any documentation in how to do this?

I’m researching and trying some alternatives, but no success for now.

Thank you

Sam

1 Like

Hello Sam.

A local repository of the Anaconda repository, one which would allow users to access the packages from a centralized, on-premise location, is referred to as a mirror. A mirror can be complete, partial, or include specific packages or types of packages.

The ability to mirror the Anaconda repository is only available with paid subscriptions to our commercial products–Pro, Business and Enterprise (some exclusions apply). Mirroring is not permitted for users of our free software, Anaconda Distribution. If you are not an Anaconda customer but would like the ability to mirror our repository, we’d be happy to help! You can reply here or go to our contact or pricing page:

However, you can create private custom channels with the free open source distribution of Anaconda.

Channels are the path that conda takes to look for packages. The easiest way to use and manage custom channels is to use a private or public repository on Anaconda.org. If you designate your Anaconda.org repository as private, then only you and those you grant access to can access your private repository.

And, if you do not want these packages uploaded to the internet, you can build a custom repository which is served either through a web server or locally using a file:// URL.

Instructions for creating custom channels can be found here:
https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/create-custom-channels.html#creating-custom-channels

I hope that this answers your questions. If you need further assistance, please let us know.

Hi @User_Care_Team

Thank you so much for sending over the information, I was reading the documentation, and I think having a custom channel would be good enough for my environment.

Let me explain my idea and then you can see if it does make sense:

I would like to have a “Server” machine are I will be installing the packages, my idea was to share the directory to create a channel to my client computers that will not have access to the internet.

What I already did:

-Created a local directory C:\Anaconda3\anaconda.mycompany\pkgs\main\win-64
-Download all the packages .bz2 from main/win-64
-Moved all .bz2 files to my local directory created in the first step.
-Installed conda-build (conda install conda-build)
-Tried to run conda index (conda index “the directory described in the first step”), but got errors.

Thank you again for looking into this.

Let me know your thoughts.

Sam

You might be interested in quetz which supports mirroring non-commercial repositories (such as conda-forge), and setting up custom channels with user permissioning: GitHub - mamba-org/quetz: The Open-Source Server for Conda Packages

It does require some technical expertise to set up and is not affiliated with or supported by Anaconda so I doubt anyone here will be able to help any issues you run in to

Also FYI as Kim already mentioned the following step you listed is a violation of Anaconda’s terms of service unless you have an explicit license with them:

-Download all the packages .bz2 from main/win-64

Hi @Damian_Shaw

Thank you for your reply.

I will be investigating the options you suggested.

I didn’t know about the Anaconda’s terms of service, I will get in touch with them to see the commercial options.

Thank you.

Sam

We have a company/internal conda channel for packages that we developed ourselves. It is on a network drive so other employees can reach it. A file-based conda channel does not have to be located in your Anaconda installation directory

What we did:

  1. Create a path on the network drive: Z:\conda_channel
  2. Create 2 subfolders in Z:\conda_channel: win-64 and noarch
  3. Put your *.tar.bz2 package in noarch or win-64
  4. Open Anaconda Prompt, make sure conda-build is installed (I use 3.21.8)
  5. Navigate to Z:\conda_channel (not to the subfolders)
  6. Run conda index . (note the period to run index on the current folder!)

Finally, we serve the channel using an Apache server to the employees, mostly to prevent one of them from accidentally changing some of the files…

For internal or self-developed packages, you can try Proget: ProGet Downloads – Inedo
Since a month or so, it includes the feature to set-up a conda channel. Be sure to use the latest release (any release before today , april 15, contains a bug regarding conda channels)

1 Like