Translation(s): none


Veewee is a tool for easily (and repeatedly) building custom Vagrant base boxes (VirtualBox format), KVMs, and virtual machine images.

Creating a Vanilla Debian7 Vagrant base box

This will not create an Official Debian Image

The box created here miss the following steps to be called Official Debian Image:

  • puppet and chef are installed via ruby gems, not using debian packages
  • The Veewee template is not maintained inside the Debian Infrastructure
  • Ideally Veewee should be available as a Debian Package

Install VirtualBox

apt-get install virtualbox linux-headers-amd64

Install Veewee requirements

apt-get install ruby ruby-dev build-essential libxslt1-dev libxml2-dev

Install Veewee as a Ruby gem

gem install fog --version 1.8
gem install veewee

List available templates and notive how those for debian are outdated

veewee vbox templates | grep Debian

Get updated veewee definitions (ie local templates)

git clone https://github.com/russkel/puppet-vagrant-boxes
cd puppet-vagrant-boxes

Veewee chokes on downloading the guest additions, we have to do it ourselves: you'll get this error

Downloading vbox guest additions iso v  - http://download.virtualbox.org /virtualbox//VBoxGuestAdditions_.iso
Checking if isofile VBoxGuestAdditions_.iso already exists.
Full path: /root/puppet-vagrant-boxes/iso/VBoxGuestAdditions_.iso
/usr/lib/ruby/1.9.1/open-uri.rb:346:in `open_http': 404 Not found (OpenURI::HTTPError)

Download the virtualbox Guest Additions

wget http://download.virtualbox.org/virtualbox/4.1.18/VBoxGuestAdditions_4.1.18.iso -O iso/VBoxGuestAdditions_.iso

Start building the VM

veewee vbox build debian-710-x64-vbox4212
veewee vbox export debian-710-x64-vbox4212

At this point you will see the VM in VirtualBox and you can use it normally.

Export from VirtualBox with to Vagrant Box format:

/usr/bin/vagrant package --base debian-710-x64-vbox4212 --output debian-710-x64-vbox4212.box

Using the freshly created box in Vagrant

Add your new Vagrant Base box to your base box list

/usr/bin/vagrant box add my_debian7 debian-710-x64-vbox4212.box

Start a new Vagrant env using it:

cd /tmp
/usr/bin/vagrant init my_debian7