I'm looking for ways to manage the installation of non-distro software, with multiple versions of the same software installed simultaneously. For example we'd have ProgramA 1.6 and ProgramB 1.7 installed simultaneously, and users would be able to switch between them.
A common solution to this seems to be environment modules which I know is used with success at many academic sites. Users can then just run module load ProgramA/1.6
and then running ProgramA
would get them the right version. So conceptually I can maintain a repository of all the modulefiles which users would use to activate the right environment.
My problem lies mostly with creating a reproducible way to actually build the software used by the modules. I'd need a reproducible way to build each software package. What would be a good way to do this? Is it possible to achieve with RPMs in an alternate root location and/or alternate RPM db? Is there another tool I could use to manage the software builds? Should I just cobble it together with shell scripts?
The platform we're running on is Scientific Linux 6, which is basically equivalent to Red Hat 6.
You could set up your own repository and create RPMs for your software.
If you keep multiple versions in the repository you can easily install the desired version via yum cli.
For setting up your own repository see here: click
Suggestions:
alternatives
command.One reasonably simple way of achieving this would be to use Stow to install each software version to its own location, then either allow users to use
stow
(e.g. viasudo
) to repoint the application version, or use shell functions to resetPATH
to point to the different software version.I do something similar to this (without
stow
) for Sybase servers which have multiple database versions running on them. I have a script calledsetenv.sh
which looks something like: