LowellObservatory / TheSyndicate

Files and other information associated with the Lowell Software Syndicate.
0 stars 1 forks source link

"Docker" vs "virtual environments" and "pipenv" #4

Open dyerlytle opened 5 years ago

dyerlytle commented 5 years ago

When I was at USGS we used Python virtual environments. I see that Ryan recommends Docker. There is also pipenv to consider. What are the advantages and disadvantages of the various environment packaging systems and which can be used together and which would be better for our situation? Perhaps we can talk about this with the group.

It looks like Docker is more like a virtual machine than just a Python virtual environment. Is there overhead associated with the use of Docker images?

astrobokonon commented 5 years ago

Python virtual environments

For this, I'm grouping virtual environments (ostensibly managed via conda) along with pipenv since they're fairly similar. I'll edit this as needed.

Pros

Cons

astrobokonon commented 5 years ago

Docker

I'm using "docker" below as a standard/stand-in term much like one can use "xerox" as a verb for "photocopy." Any virtualization solution could be used, such as Kubernetes (which still supports docker formats) or really any kind of Linux container platform.

Pros

Cons

astrobokonon commented 5 years ago

Summary

A hybrid approach might make the most sense?

conda or pipenv type environments might make the most sense for developers locally, but CI setups (like travis) basically use docker under the hood for builds so that's a strong consideration to bring docker into the mix earlier.