These two scripts demonstrate the ideas backing my approach for putting together files that enable offline deployment of a Python computing environment. I don't strictly promise that they run without tweaking.
The packaging has to be done on a system similar enough to the target system for installation. For instance, if one intends to deploy the environment on a Intel 64-bit CPU system (x86-64 architecture) running Linux, run package-wheels.sh
on a x86-64 Linux box that has Internet access. No need for strict version matching of kernels and LibC, unless the target system is much older than the one I'm packaging from. Virtual machines are useful for packaging, as are temporary cloud nodes. Myself, if I find myself without a system at hand that matches the target, I love using Digital Ocean for quick VM instantiation and tear down: I run my packaging, transfer the archive of wheels to my local computer, and boom! done. For the 30 minutes the whole thing might take, the cost I incur amounts to a few cents