Specify Vagrantfile path explicity, if not plugin

Further to Andrew Lorente’s answer, you can also use the VAGRANT_VAGRANTFILE environment variable to specify the filename of the Vagrantfile. This has the advantage over VAGRANT_CWD of not changing the current working directory which can be useful when relying on relative paths. For example, the following will run vagrant up on Vagrantfile.other: VAGRANT_VAGRANTFILE=Vagrantfile.other vagrant up … Read more

How do I SSH into the boot2docker host vm that the Vagrant 1.6 Docker Provider sets up?

Vagrant’s boot2docker keeps boot2docker’s ssh username and password. SSH into VM $ boot2docker ssh Boot2Docker auto logs in using the generated SSH key, but if you want to SSH into the machine manually (or you’re not using a boot2docker managed VM), the credentials are: user: docker pass: tcuser https://github.com/boot2docker/boot2docker#ssh-into-vm The port is forwarded from the … Read more

vagrant with multiple sync’d folders [closed]

2021 Update: In 2021 no need for unique Id or being nfs, just list your synced folders: config.vm.synced_folder “.”, “/vagrant/Sites” config.vm.synced_folder “../Code”, “/vagrant/Code” Original answer: I just needed to set a unique ID for each mount, and then reload the vagrant box. # Use NFS for the shared folder config.vm.synced_folder “.”, “/vagrant/Sites”, id: “sites”, # … Read more

Vagrant provisioning shell vs puppet vs chef

The following article concerns yet another CM tool (ansible), but I think the author does an excellent job of explaining the benefits of transitioning away from shell scripts. http://devopsu.com/blog/ansible-vs-shell-scripts/ quote 1: What really surprised me was the response from some of these more famous devs. They basically said, “This is really cool, but I probably … Read more

Vagrant: how to configure multiple NICs within a Vagrantfile?

Using Vagrant 1.6.1 and private networking with Virtualbox you can create multiple private ips just by repeating the config.vm.network definition: # Vagrantfile API/syntax version. Don’t touch unless you know what you’re doing! VAGRANTFILE_API_VERSION = “2” Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| config.vm.box = “precise64” config.vm.network “private_network”, ip: “192.168.50.4” config.vm.network “private_network”, ip: “192.168.50.5” config.vm.network “private_network”, ip: “192.168.50.6” config.vm.network “private_network”, … Read more

can’t connect localhost:3000 ruby on rails in vagrant

The solution is running the code below to start your server: rails s -b 0.0.0.0 I found this solution from another post about same problem. The answerer said ‘You’ll want to make sure that the server is binded to 0.0.0.0 so that all interfaces can access it.” I hope this post helps people who encounter … Read more

Vagrant up error in headless Ubuntu: The guest machine entered an invalid state while waiting for it to boot

According to mitchellh Can you start the machine manually (from the GUI)? This error message is usually indicative of VirtualBox issues. my solution I use vagrant under windows though, I solved this problem by simply kill all the VirtualBox process, and restart VirtualBox GUI, start the VM, then normally power off it. maybe useful links … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)