On 5 April 2018 at 11:11, Eric Gorr <ericg...@gmail.com> wrote:
> I had a question about distributing python packages to offline machines when
> the offline machine is running a different OS then a machine with an
> internet connection. The packages I am concerned with are third party upon
> which mine depend.
>
> Based on what I have learned so far, there are three solutions.
>
> (a) Use a CI to run a fleet of machines for each OS one needs to target to
> obtain the OS specific wheels.
>
> The issue I see with (a) is the shear amount work it would take to setup and
> maintain such a system.

Depending on just how many packages and how many operating system
versions are involved, this option may be less work that you
anticipate, thanks to the excellent wagon project from Cloudify:
https://github.com/cloudify-cosmo/wagon

Keep a requirements.txt file or `Pipfile` in source control, then run
CI jobs based on that repo to emit wagon files with all the required
wheels embedded in them (either sourced from PyPI, or built locally in
CI as needed).

Cheers,
Nick.

P.S. See 
https://github.com/cloudify-cosmo/wagon/issues/30#issuecomment-374096806
for the technique of supplying a dummy setup.py file that gives wagon
the metadata it wants, without actually needing to define a full top
level "application" package.

P.P.S Depending on how strict the requirement is for "offline wheel
files" vs "offline prebuilt binary dependencies", it may also be worth
your while to explore
https://www.paypal-engineering.com/2016/09/07/python-packaging-at-paypal/
(regarding the use of conda as a Python platform manager) and
https://conda.io/docs/user-guide/tasks/create-custom-channels.html
(regarding the creation of tar-friendly custom conda channels)

-- 
Nick Coghlan   |   ncogh...@gmail.com   |   Brisbane, Australia
_______________________________________________
Distutils-SIG maillist  -  Distutils-SIG@python.org
https://mail.python.org/mailman/listinfo/distutils-sig

Reply via email to