5 ms·
A lot of python shops I've come across don't use the system installed python or ruby. In python land at least it's exceedingly common to deploy a virtualenv wit
by treystout 12y ago
A lot of python shops I've come across don't use the system installed python or ruby. In python land at least it's exceedingly common to deploy a virtualenv with a separate python runtime and isolated 3rd party libs. This makes pinning your version deps easier and doesn't matter if the underlying server is ubuntu or centos or whatever.
- paukiatwee 12y agoThat is true, what if in future ubuntu/centos include Go by default (which might not the version you use)? I believe then will have some GVM or similar tool to solve the problem. Edit: As others pointed out, Go is compiled binary and does not required runtime (like JVM) so versionning is not issue. Thanks for clearing up.
- kasey_junk 12y agoNot being a Go developer I don't understand why this would be the case. Doesn't Go compile code to a binary? Why should Go even be required on the server?
- Supermighty 12y agoThere won't be a need for a GVM as Go is not a stand-alone runtime. Once compiled for a specific platform it will just run. You don't even need it installed on the server. You can cross-compile on your DEV machine and move the binary LIVE. Then it just runs. It doesn't need any libraries on the server.
- kasey_junk 12y agoDoes Go not have the concept of linking? If you are deploying several Go applications on the same server that each use libraries, does it include duplication of libraries in every binary?
- Supermighty 12y agoThere is no linking. Each Go binary has all of the libraries it needs baked into it. So if you have multiple different Go applications on one server, and they use some of the same libraries, then each application's binary will contain a copy of that library. It makes things a little redundant, but also simplifies the deployment process. edit: The only exception is if you are using cgo and liking to existing C libraries. In pure Go there is no linking.
- NateDad 12y agoAll Go applications are statically linked. There are no libraries. It's a single executable that you can copy to your target machine and run.
- NateDad 12y agoGo applications require no installed runtime, they compile to native code. You can have no Go installed or any Go installed on the system, and the executable will neither know nor care.
- NateDad 12y agoYeah, many of the ruby applications I've seen recommend RVM so that you can isolate yourself from the system-installed version of ruby. That's the nice thing about go - each application carries around everything it needs to run in total isolation from the rest of the machine.
- icebraining 12y agoExcept for libc, of course. By the way, you can actually do the same for Python using cx_Freeze; it'll create a single executable with Python + libraries + you code. [1] http://cx-freeze.readthedocs.org/en/latest/script.html#script http://cx-freeze.readthedocs.org/en/latest/script.html#scrip...
- NateDad 12y agoI should just stop making assumptions about python and assume that if there's anything you ever would like to do with python, that someone has already built it :)