6 ms·
Toward Vagrant 3.0
- vasergen 5y agoI was surprised to see growing ecosystem and community. I though that docker would take mainstream in virtualization, so main usecase for vagrant would be when you really need a virtual machine.
- tommek4077 5y agoNot everyone is building Javascript websites... ehm... I mean Apps
- kstrauser 5y agoDocker has never been about such things, even if it's a nice solution for developing them.
- sneak 5y agoDocker isn't virtualization, and AFAIK has never really made any moves in that direction outside of small, local dev (eg running a local VM on a non-Linux host to get a local dockerd-on-Linux available).
- andrewmcwatters 5y agoI'm late to using Vagrant, hands-on. I used it years ago, but didn't build my own Vagrantfiles. It seems to be a very nice programmatic wrapper around using, primarily, VirtualBox's Unattended Guest Installation[1], though it can use other providers, too. But I've noticed that it seems like you can skip straight to using docker containers for development environments as well. I'm wondering what other people's experience here is with both or either software. In my opinion, both still seem like relevant software. When I need an Ubuntu development environment on my Mac, I don't turn to Docker. I think of Vagrant right now, because that's what it was built for. Vagrant is a tool for managing virtual machines and development environments.[2] [1]: https://www.virtualbox.org/manual/UserManual.html#basic-unattended https://www.virtualbox.org/manual/UserManual.html#basic-unat... [2]: https://www.vagrantup.com/intro/vs/docker https://www.vagrantup.com/intro/vs/docker Edit: Thank you for the excellent insights!
- deleted 5y ago[deleted]
- woodruffw 5y agoI've used both extensively. At least in my case, my uses are slightly different: * Docker is nice for consistent development and deployment environments, particularly when I'm on a macOS host and I'm doing userspace programming. * Vagrant is nice for creating a completely hermetic development environment, both on macOS and Linux hosts. My particular use case has been kernelspace programming: it's nice to not have to worry about accidentally taking my host down. Docker can't provide that kind of isolation, since it's still running on the host (or host VM) kernel at the end of the day.
- 8bitbuddhist 5y agoThe way I see it, Vagrant does for VMs what Docker does for containers: provides a way to build, deploy, manage, and teardown VMs consistently and without much manual effort. For example, I used Vagrant when learning to use Kubernetes, because I could quickly spin up a 3 node cluster on my laptop and destroy it if I messed up. If you can use containers for local dev, great, but not everyone can or wants to migrate to containers. Vagrant still solves a very important use case.
- nonameiguess 5y agoA VM can still use systemd as init rather than an entrypoint script, so if you're developing systemd units, you need a VM. There is also the issue of running your application in a container in the first place. Docker in Docker is possible, but cumbersome. Redhat has certainly made it easier with Podman, but Docker still dominates developer mindshare. It's also quite a bit easier to persist changes in a VM, so rather than rearchitecting the OS or toolchain secrets management, user-specific configuration in a VM can just be done by the user after first launch and it sticks around. Simpler to do that than providing instructions and capability to mount git credentials store and gpg trust dbs into a container, then worrying about making sure you have the same UID in the container and out of it, so you don't mess up permissions. Containers are largely just not a great medium for interactive work, i.e. development. They're great for resident applications that use a single process run via a service account.
- la_fayette 5y agoWe use vagrant with ansible to build a local dev environment and almost the same production environment from the same ansible project. We experimented with docker, but it is still extremly slow on windows and our production machine is provisioned with ansible, so vagrant is a natural fit... Very happy most of the time, only some strange ssh errors happen from time to time...
- redsymbol 5y agoThis is exactly what we do. It is like having a locally run staging environment, and is really great. Can exactly test things like http server configuration, cron jobs, multiple nodes (vagrant vms) coordinating with each other, etc.
- mitchellh 5y agoHello HN! I'm one of the founders of HashiCorp and original creators of Vagrant. Vagrant isn't "HN hip" these days ;) and I feel like folks tend to think if they don't see it here it must be dead. Vagrant has been the opposite: downloads have still only gone up, and we're seeing it used in more and more places on the regular. Most people are quiet about it because it does what it was built to do well and quite honestly, its moved more into the stereotypically "boring" organizations. For example, I recently ran into an engineer that works at a local city utility who was raving about how they just adopted Vagrant last year and it has been completely life-changing for their team. This is 2021, Vagrant came out 2012. Products have super long lifecycles and the market is massive. Regardless, we've remained committed to Vagrant. We've always had a team dedicated to Vagrant, and the Vagrant team is awesome and has continued to push out new features and new releases for the past decade. We're super excited for Vagrant 3.0! There's a lot we have planned for it and the transition to Go is going to bring a lot of those improvements. I think one topic that is interesting for the HN crowd: why are we rewriting Vagrant in Go? Is that too expensive or time consuming? Does that cause too much user pain? HashiCorp has built dozens of products now in Go and we've built a large foundation of libraries and utilities for Go-based projects. All our products share the same CLI library (that we wrote), the same plugin framework (that we wrote), the same distributed systems libraries (that we wrote), etc. Besides code, we've built a security team and release engineering team that has pipelines ready to go for Go-based projects. And more. This means that we move fast with Go, and we can do it confidently, and we can do it without a lot of overhead. From the moment we decided to port Vagrant to Go, the Vagrant team had a working demo in just a few weeks, and an "alpha" release they're ready to ship to users in a few months. We got this speed cause we just wrapped Vagrant around the same architecture and libraries that our other products are built on. For our users, there are a bunch of improvements (mentioned in the blog post). We're being very careful about backwards compatibility and have a multi-year plan to ensure that existing Vagrantfiles and plugins continue to work. We're starting with continuing to embed a Ruby with our installers while the core is running Go. Over time, we'll ask users to bring their own Ruby (and we'll validate it) to use "older" Ruby-based plugins and Vagrantfiles. Feel free to ask any questions, I'll try to be present in this thread. ----------------------------------------------------- Also, if you're a Vagrant user, we also recently made our VMware plugin free and open source. Check it out: https://twitter.com/mitchellh/status/1402729560823664641 https://twitter.com/mitchellh/status/1402729560823664641
- aidos 5y agoHas anyone had any success with a vagrant provider on Apple Silicon now that virtual box is now out of action? We’re using UTM, which does the job as a frontend to qemu, but it’s be nice to switch back to a vagrant based declarative file.
- u678u 5y agoAfter struggling with KVM networking I just gave up and used cloud VMs. Should I give Vagrant a try instead?