Live data from Hacker News

Vagrant 2.0

hashicorp.com

81–90 of 120 posts

Re: Vagrant 2.0

#81

There are still times I look to Vagrant instead of, and alongside, Docker. The reason being Docker for Mac uses a VM anyway (an xhvye machine) - it does try to hide/abstract this away, but inevitably this leaks. The xhyve VM has the usual parameters memory, diskspace, CPUs, and not least a kernel. There are limited options to fiddle with these parameters, though you can log into it and poke around there. I thus find…

Vagrant with KVM/libvirt works great on Linux and doesn't stop you from using docker. VirtualBox is inconvenience on Linux, not Vagrant

Re: Vagrant 2.0

#82

Since many people are still not too familiar with Vagrant (it doesn't seem to have the cachet of Docker for local dev environments), here are a few example Vagrant configurations that I use to build different servers for local testing/debugging: https://github.com/geerlingguy/ansible-vagrant-examples There are plenty of other great examples of Vagrant usage around the web, too, from Laravel's Homestead to (disclosure…

When I started learning Ansible, I kept running into your stuff on the Ansible Galaxy [0]. Such a peculiar name, it stuck with me. Thanks very much for your contributions!

Vagrant is probably the best way to go about learning automated configuration management with ansible, and especially Puppet. And I've never tried it myself, but I hear people setting up local OpenStacks with Vagrant, too. Not a bad way to get your feet wet.

[0] https://galaxy.ansible.com/

Re: Vagrant 2.0

#83
post #16

since i am using docker-compose locally, i have little use for vagrant nowadays. For staging and production the docker containers run inside a Kubernetes environment which i don't want to replicate locally. Am i missing something ?

We have had a number of people want to replicate locally for offline use cases (train/plane), reduced bandwidth use cases (home/plane/train), and cost reasons (laptop VMs are always cheaper than cloud). If you like Vagrant and Kubernetes checkout the Tectonic Sandbox[1] or if you don't want to use vagrant checkout minikube[2]. We (CoreOS) invested time into both projects for these reasons.

[1]: https://coreos.com/tectonic/sandbox [2]: https://github.com/kubernetes/minikube

Re: Vagrant 2.0

#84

There are still times I look to Vagrant instead of, and alongside, Docker. The reason being Docker for Mac uses a VM anyway (an xhvye machine) - it does try to hide/abstract this away, but inevitably this leaks. The xhyve VM has the usual parameters memory, diskspace, CPUs, and not least a kernel. There are limited options to fiddle with these parameters, though you can log into it and poke around there. I thus find…

Vagrant with KVM/libvirt works great on Linux and doesn't stop you from using docker. VirtualBox is inconvenience on Linux, not Vagrant

Mostly, though the vagrant-libvirt provider is still a separate plugin, and hasn't reached 1.0 yet, probably due to several rough edges.

edit: I should also mention that vagrant-libvirt doesn't even work on Vagrant 2.0.0, due to https://github.com/vagrant-libvirt/vagrant-libvirt/issues/76...

Re: Vagrant 2.0

#85

Since many people are still not too familiar with Vagrant (it doesn't seem to have the cachet of Docker for local dev environments), here are a few example Vagrant configurations that I use to build different servers for local testing/debugging: https://github.com/geerlingguy/ansible-vagrant-examples There are plenty of other great examples of Vagrant usage around the web, too, from Laravel's Homestead to (disclosure…

> Since many people are still not too familiar with Vagrant (it doesn't seem to have the cachet of Docker for local dev environments) That's only a recent trend. Up until Docker became the standard a couple years ago (or whenever Docker for Mac was made stable), Vagrant was the standard for dev environments. The primary reason Docker succeeded Vagrant for dev environments is speed. Docker can have my dev environment…

I once worked on a project which used Vagrant as its officially recommended local dev environment.

Every time I had to set it up from scratch, it took me -- and I was not a novice, and knew the stack well -- a day or more and many, many failures to get running. Thankfully, I think the project has since abandoned Vagrant.

(and Docker isn't much better in my experience)

Re: Vagrant 2.0

#86
post #69

Earlier quoted context omitted.

> Since many people are still not too familiar with Vagrant (it doesn't seem to have the cachet of Docker for local dev environments) That's only a recent trend. Up until Docker became the standard a couple years ago (or whenever Docker for Mac was made stable), Vagrant was the standard for dev environments. The primary reason Docker succeeded Vagrant for dev environments is speed. Docker can have my dev environment…

Also the early reliance on virtualbox was a performance issue for some build environments even once they were up. I have at least one C++ project that (for windows) takes 8x as long to build on vbox vs. a real machine.

Wow, it doesn't rely on VirtualBox anymore? I remember using it before for the development environment of an old company, and that being a small nuisance.

Nowadays, Docker is really miles ahead in terms of usage in development environments. Vagrant was pretty easy to set-up and use back then, but now Docker is much, much easier.

Re: Vagrant 2.0

#87

Earlier quoted context omitted.

> Since many people are still not too familiar with Vagrant (it doesn't seem to have the cachet of Docker for local dev environments) That's only a recent trend. Up until Docker became the standard a couple years ago (or whenever Docker for Mac was made stable), Vagrant was the standard for dev environments. The primary reason Docker succeeded Vagrant for dev environments is speed. Docker can have my dev environment…

I once worked on a project which used Vagrant as its officially recommended local dev environment. Every time I had to set it up from scratch, it took me -- and I was not a novice, and knew the stack well -- a day or more and many, many failures to get running. Thankfully, I think the project has since abandoned Vagrant. (and Docker isn't much better in my experience)

you, and they, were doing it wrong.

The point of vagrant is that you type 'vagrant up' and you have a working environment.

All of my projects use vagrant to ensure compatibility. You can 'git clone' and 'vagrant up' and have a working environment as soon as the provisioning task completes.

Re: Vagrant 2.0

#88
post #6

In the change log, I’m happy to see “improved the resilience of some Virtualbox commands.” At Airbnb, we used to use Vagrant with Virtualbox and the Chef provisioner to create our dev environments, but we migrated totally away from Vagrant after struggling with Virtualbox bugs, and strangeness with Vagrant’s internal state and locking. Seems like this issue is finally addressed: https://github.com/mitchellh/vagrant/i…

Vagrant's really falls short of its promise of "the exact same dev environment for everyone" in my experience, especially because of VirtualBox issues such as, for example, relative symlinks breaking if done in a shared folder on a mismatched guest/host OS. It's been such a source of frustration that there is no better shared folder alternative. VirtualBox is the only usable cross-platform backend, and vbox shared fo…

We ran into sym link problems with node/npm, but these were completely resolved by keeping the node_modules folder in the VM, not sym linked out to the host:

    mkdir /home/vagrant/node_modules
    ln -s /home/vagrant/node_modules /vagrant/node_modules

Re: Vagrant 2.0

#89

Earlier quoted context omitted.

I once worked on a project which used Vagrant as its officially recommended local dev environment. Every time I had to set it up from scratch, it took me -- and I was not a novice, and knew the stack well -- a day or more and many, many failures to get running. Thankfully, I think the project has since abandoned Vagrant. (and Docker isn't much better in my experience)

you, and they, were doing it wrong. The point of vagrant is that you type 'vagrant up' and you have a working environment. All of my projects use vagrant to ensure compatibility. You can 'git clone' and 'vagrant up' and have a working environment as soon as the provisioning task completes.

Thanks for the help.

I trust that the people who provided whatever configuration it used knew what they were doing, but it was still incredibly flaky.

Re: Vagrant 2.0

#90
post #58

Does anyone find Vagrant useful for personal projects? Or is it only useful for team settings?

You need to provision one or more dev environments (for me two. On my Linux desktop and on my MacBook Air). The ansible configs are also used to provision production servers. If you end up with a failed hard drive it can save a lot of time rebuilding
Post reply on HN