Caching installed pip/conda packages

[original thread by Tuan Vu]

Hi team , I’m trying to find a way to persist installed pip/conda packages in my env. Currently, I have bash script to install pip packages . This script is executed as part of .gitpod.yml.

Right now, all the installed pip packages disappear after I reopen my env. Just wondering if you could help

1 Like

Hi @tuan-vu! In the default workspace image we’ve configured pip to install in a user site by default, and the site’s location is under /workspace to guarantee that it preserved between restarts.

You mention conda. Could you share some info, maybe the repo if it’s public. I’m happy to help you to configure it accordingly.

[Tuan Vu]

Hi Alex, I have resolved the issue by creating a conda env in workspace. This ensures that all conda packages persist through different sessions

That’s good news! If it’s a public repo, do you want to share details on this? It would be awesome for other Gitpod users how work with conda environments.

Just started working with Conda, any suggestions for installing correctly. Any repos I can look at?

[Tuan Vu]

@AlexTugarev @Rocksetta https://github.com/mtvu/miniconda

[Tuan Vu]

Let me know if you have any issues with it

@tuan-vu that is awesome to have anaconda working. Thanks for sharing.

Hello, Could you tell us what would be the best strategy to cache python pip packages (not conda)?