guix-science
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Reproducible Project Environments


From: Peter Polidoro
Subject: Reproducible Project Environments
Date: Mon, 06 Dec 2021 09:18:28 -0500
User-agent: mu4e 1.6.10; emacs 27.2

Guix is a wonderful way to distribute software, especially for science. Thank you all for such a fantastic project and community!

I am an engineer working with scientists at the Howard Hughes Medical Institute, a science philanthropy based in the United States funding researchers all over the world. I hope to help convince the researchers I work with to all use Guix someday.

My question is, what files do you recommend placing within a project directory to make it as straightforward as possible to distribute that project to others to develop and use in a reproducible environment?

If all of the project dependencies are in Guix as packages, then a guix.scm or manifest.scm file seems all that is needed to create a reproducible environment using guix shell, as long as someone has Guix installed on their machine.

What do you recommend when some of the project dependencies are not yet Guix packages? Obviously it would be best to get those dependencies into Guix as official packages eventually, but what is the best way to handle those dependencies until then?

Say that in addition to some Guix packages, the project also needs some Python packages that are available on pypi, but are not yet Guix packages. Using something like direnv, an .envrc file in the project directory can install the Guix package dependencies into a local profile, then pip install the Python dependencies into a project local virtualenv. Then the user just needs Guix and direnv installed on their machine to get a reproducible environment when they change into that directory. Specifying dependencies in an .envrc file does not seem as elegant as using a pure Guix solution, however.

What is the best way to handle these dependencies without using direnv and just Guix? Should I create Guix packages for the Python dependencies in an external custom channel? If so, how do you specify custom channels when using guix shell? Is there a method that is as simple as direnv or does it involve a user separately setting up a new profile to reference the custom channel before running guix shell?

Do you ever create packages within a guix.scm file or a manifest.scm file or perhaps in a separate channel.scm file in the project directory to keep the project more self contained than referencing an external custom channel? Then would you create some project local profile that references this file to use when running guix shell? Or is the recommended approach to always use a custom channel before submitting the packages to be included into Guix proper? Thanks!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]