Skip to content

Instantly share code, notes, and snippets.

@thangdc94
Last active June 1, 2019 01:29
Show Gist options
  • Save thangdc94/0174d60a8177ba19bd2a874297d1d93c to your computer and use it in GitHub Desktop.
Save thangdc94/0174d60a8177ba19bd2a874297d1d93c to your computer and use it in GitHub Desktop.
Rebuild Python/R Environment on a Offline Host

Download all packages with pip download -r requirements.txt and copy them to the offline host.

Install them on the offline host with pip install --no-index --find-links /path/to/some/dir/ -r requirements.txt

If you manage environment with pipenv , create the requirements.txt file from Pipfile with pipenv lock -r

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment