


Inside the “src” folder, we have set 3 others: So, we added the following folders to the VM root As a result, guest additions will be installed or upgraded as needed. Vagrant will check to see if the guest additions are already on the VM and, if yes, on which version. To have that, we just need to install a plugin: # vagrant auto upgrade guest additions Vagrant can handle VirtualBox guest additions for us. So, to completely destroy the VM, we use the command (confirm with ‘y’ when asked): # vagrant destroy If we check VirtualBox now, we can see that the VM is not running.

So, Vagrant has a command we can use for that: # vagrant halt We still need to make changes to the configuration file. We now have a basic VM but, we will stop it for now. We can check VirtualBox and see that the new VM is available and ready to be usedįigure 1: Oracle VM VirtualBox Manager with new VM already running So what if we wanted to use a different provider? In that case, we could specify it on the same command we’ve seen before, so we would end up with: # vagrant up -provider hyperv We start the VM with the command # vagrant up In this case it’s a customized box: # vagrant init example_centos7-box To initialize the Vagrant file, we need to type the command vagrant init and the name of the box. We can either use a custom box (see how to create one here) or use an existing one from here.

We start by creating an initial Vagrant configuration file specifying the box we want to use. For that purpose, we’ve used Vagrant (under MIT license) and, in this example, VirtualBox base package (under GPLv2). No manual work to deploy configurations / tools every time we need a new distribution. Creating a Dev VM should be simple and easy.
