--- vm-builder-0.11.orig/debian/changelog +++ vm-builder-0.11/debian/changelog @@ -0,0 +1,375 @@ +vm-builder (0.11-0ubuntu2) karmic; urgency=low + + * fix traceback due to unchecked ec2 attribute reference (LP: #403216) + * fix parted linux-swap --> linux-swap(new) naming convention (LP: #399428) + * fix for vol_id dropped in favour of blkid in karmic udev + + -- Dominic Evans Fri, 24 Jul 2009 12:56:20 +0100 + +vm-builder (0.11-0ubuntu1) karmic; urgency=low + + * New upstream release. + + -- Soren Hansen Tue, 09 Jun 2009 10:10:54 +0200 + +vm-builder (0.10-0ubuntu2) jaunty; urgency=low + + * fix traceback due to kpartx failure (LP: #342359) + - VMBuilder/disk.py: sleep a few seconds to give the loopback devices + a chance to settle down, then try to unmount. If it fails, try a few + more times and if still fails, error out as before + * fix FTBFS due to python2.6 transition (LP: #354849) + - debian/python-vm-builder-ec2.install: use python2.6/dist-packages path + - debian/python-vm-builder.install: use python2.6/dist-packages path + + -- Jamie Strandboge Fri, 10 Apr 2009 10:23:19 -0500 + +vm-builder (0.10-0ubuntu1) jaunty; urgency=low + + * New upstream release. + + -- Soren Hansen Thu, 19 Feb 2009 00:28:02 +0100 + +vm-builder (0.9-0ubuntu6) UNRELEASED; urgency=low + + [ Jamie Strandboge ] + * fix creation of Dapper VMs (LP: #305186) by moving existing + copy_settings() from plugins/ubuntu/dapper.py to plugins/ubuntu/edgy.py + and creating a Dapper specific copy_settings(). This was introduced in + fix for (LP: #292573). + + [ Michael Vogt ] + * when --ssh-key is given, install openssh-server + + -- Jamie Strandboge Thu, 04 Dec 2008 08:48:39 -0600 + +vm-builder (0.9-0ubuntu5) jaunty; urgency=low + + * add Jaunty support + + -- Jamie Strandboge Wed, 03 Dec 2008 17:41:12 -0600 + +vm-builder (0.9-0ubuntu4) jaunty; urgency=low + + [ Nicolas Barcet ] + * Integrate ec2 postinstall script + * Add --install-mirror to fix LP: #291639 + * Implement --iso to fix LP: #291590 + * Install openssh-server cleanly LP: #293039 + * Xen kernel and ramdisk are now dynamically discovered rather than + hard coded + * Add --xen-kernel and --xen-ramdisk to override automatic discovery + * Add --net-virtio and --net-bridge option to libvirt plugin + * The libvirt plugin now errors out if used with something else than KVM, as + nothing else is supported yet. + * For FSIMAGE type file system, --part now accepts a third argument which + allows to specify the device the partition should be mapped to. If the + size is set to 0, it is considered a "dummy" partition that should not be + created, only added to fstab. + + [ Chuck Short ] + * Add retry option when uploading to Amazon + * Install server and standard seed by default + * Add ec2 examples for first login and first boot + + [ Eric Hammond ] + * Fix post_install bugs LP: #292888, LP: #292891 & LP: #292901 + * Fix regression on locale settings LP: #292573 + + -- Soren Hansen Mon, 01 Dec 2008 10:31:35 +0100 + +vm-builder (0.9-0ubuntu3.1) intrepid-security; urgency=low + + * SECURITY UPDATE: vm-builder creates predictable root password when + creating virtual machines (LP: #296841) + - VMBuilder/plugins/ubuntu/dapper.py: invoke chpasswd with '-e' + - CVE-2008-XXXX (to be filled in) + + -- Jamie Strandboge Tue, 11 Nov 2008 16:05:56 -0600 + +vm-builder (0.9-0ubuntu3) intrepid; urgency=low + + [ Johan Euphrosine ] + * Fix exception when suite provided does not exist (LP: #281801) + and provide unit test for it. + + [ Chuck Short ] + * Added parameters required for EC2 plugin. + * Use ec2_name instead of hostname when submitting an AMI. + * Update xen_kernel_path and xen_ramdisk_path for intrepid. + * Default to amazon kernels/ramdisk pairs for now. + * Split out ec2 module into its own package. (LP: #284762) + + [ Nicolas Barcet ] + * Error out if domain is undefined (LP: #280125) + * Fix --dest so that it is actually used now (LP: #280091) + * Fix -c handling, values are now used (LP: #279159) + * Create /var/run/network to fix bug LP: #276365 + * Handle fsimage type vms (Xen) in fstab and (hopefully) libvirt (LP: #282109) + * Components where not parsed correctly (LP: #283263) + * preflight_check() was called twice in a row in vm.py for no aparant + reasons + * Change default suite to intrepid + * Intrepid needs groot=uuid, else update-grub tries to outsmart us later on + and it won't boot as it cannot guess the uuid right. + * Couple fixes when calling devletters, which is a function + * Double parenthesis removed in devicemap.tmpl + * Added function isDomain to fix bug LP: #284746 + * Documented unusual conf name value in help to fix bug LP: #284614 + * Fixed a bug in set_defaults occuring on reading untyped value from the + configuration file + * Match ec2 vocabulary by adding option name and clarifying help + (LP: #284765, LP: #285170, LP: #285165) + * Added a check for xen hypervisor when ec2 is selected (LP: #285191) + * Added checks for presence of bucket, access key and secret key for ec2 + (LP: #284757) + * Older suite need 128 bit inode for grub to recognize os. Thanks to Albert + Damen for the pointer (LP: #285093) + * The libvirt plugin now errors out if used with something else than KVM, as + nothing else is supported yet. + * Write out disk info in vmware's .vmx, converting it to use template while + at it (LP: #286487) + * Add 'config.version = "8"' to vmware.tmpl to fix LP: #286531 + + [ Mathias Gug ] + * Fix --templates option. + + [ Soren Hansen ] + * Create /var/{run,lock} on the root filesystem, just like d-i. + + -- Soren Hansen Fri, 24 Oct 2008 13:15:23 +0200 + +vm-builder (0.9-0ubuntu2) intrepid; urgency=low + + [ Nicolas Barcet ] + * Added hint for more help (LP: #269323) + * Added firstscripts plugin to fix regression on --firstboot and --firstlogin (LP: #268957) + * Added postinst plugin to fix regression on --exec and add --copy (LP: #268955) + * Added man page. + + [ Soren Hansen ] + * Include ubuntu-vm-builder package. (LP: #277272) + * Read additional config file given by '-c'. (LP: #276813) + * Fix regression from ubuntu-vm-builder: Make output from subprocess + non-buffered. + * Let --overwrite apply for libvirt as well. (LP: #276322) + + -- Soren Hansen Fri, 03 Oct 2008 18:52:06 +0200 + +vm-builder (0.9-0ubuntu1) intrepid; urgency=low + + [Nicolas Barcet ] + * Fixed regression on --ip and friends (LP: #268920) + * Added missing dependancy on dpkg-dev (LP: #270324) + * Fixed regression on --part (LP: #268718) + + -- Soren Hansen Wed, 24 Sep 2008 09:58:35 +0200 + +vm-builder (0.8.1-0ubuntu3) intrepid; urgency=low + + [Soren Hansen ] + * Re-add VMWare support. (LP: #268140) + * Fixed sources.list generation for Ubuntu. (LP: #268155) + * Added configuration file handling. (LP: #268170) + * Fix up Xen support (device and configuration file creation). (LP: #268142) + + -- Soren Hansen Tue, 09 Sep 2008 17:01:02 +0200 + +vm-builder (0.8.1-0ubuntu2) intrepid; urgency=low + + * Apply patch to only conditionally import libvirt. Fixes FTBFS. + + -- Soren Hansen Thu, 04 Sep 2008 09:50:27 +0200 + +vm-builder (0.8.1-0ubuntu1) intrepid; urgency=low + + * Added lots of inline documentation. + * Build documentation using epydoc. + * Moved libvirt support to a separate plugin. (LP: #264605) + * Deploy directly to libvirt (regression from ubuntu-vm-builder). (LP: #264604) + * Updated debian/{copyright,control} to reflect move on Launchpad. + * No longer a native package. + + -- Soren Hansen Thu, 04 Sep 2008 09:33:29 +0200 + +vm-builder (0.8) intrepid; urgency=low + + * Rewrote the entire thing in Python. + + -- Soren Hansen Sat, 05 Jul 2008 00:23:20 +0200 + +ubuntu-vm-builder (0.7~ppa2) intrepid; urgency=low + + [Thierry Carrez] + * Patch to fix lilo prompt (fix LP: #206763) + + [Loic Minier] + * Add support for "security mirror"; --security-mirror flag, SECURITY_MIRROR + config; defaults to security.u.c/ubuntu for official arches and to + ports.ubuntu.com/ubuntu-ports for lpia. + + [Nicolas Barcet] + * Merge --in-place option from Hardy. + * Fix case when domain is not defined on the host, thanks to Thierry Carrez + (LP: #237580) + * Fix console-setup the good way (by copying /etc/console-setup) thanks + again to Thierry Carrez (LP: #237616) + * Fix config-handler to not break with --arch option + * Change config handler to use default and etc configurations as well + * Make VMHOSTNAME more meaningfull by default + + -- Nicolas Barcet Tue, 18 Jun 2008 18:59:18 +0200 + +ubuntu-vm-builder (0.7~ppa1) intrepid; urgency=low + + [Michael Vogt] + * Add Intrepid to the suites + + [Loic Minier] + * Fix unchecked usage of $SUDO_USER which might be unset when creating the + configuration. + * Set LIBVIRT URL to the empty string if it isn't set in the env. + + [Nick Barcet] + * Added -c option to specify an alternate configuration file + + -- Nicolas Barcet Fri, 31 May 2008 00:14:00 +0200 + +ubuntu-vm-builder (0.4-0ubuntu0.3) hardy-proposed; urgency=low + + * Add --in-place option that will allow ubuntu-vm-builder to function when + $TMPDIR is nodev and/or nosuid. (LP: #228744) + + -- Soren Hansen Tue, 03 Jun 2008 14:43:51 +0200 + +ubuntu-vm-builder (0.6) intrepid; urgency=low + + * Release into Ubuntu proper. + + -- Soren Hansen Wed, 28 May 2008 11:36:02 +0200 + +ubuntu-vm-builder (0.5ubuntu1~ppa4) intrepid; urgency=low + + [Loic Minier] + * Call sh -c "$EXEC_SCRIPT" instead of "$EXEC_SCRIPT"; allows to pass + arguments to the script; also remove check that EXEC_SCRIPT exists. + + [Nick Barcet] + * Adding an error handler to fix LP: #217950 + * Lots of sanitization to allow for error handler + * Add an interrupt handler to cleanup if user interrupts script + * Stop on error in user script to fix LP: #228675 + * --ssh-key adds key to root and --ssh-user-key adds key to user + * Added --raw option to install on raw devices/files. + WARNING: the variables used in template files for disk definition have been + modified. Please insure that locally created templates are updated to + reflect this change. + * Add --firstboot and --firstlogin options + * First login always execute "sudo dpkg-reconfigure console-setup" so + that the local keyboard setting is taken into account. + * Adding the --iso parameter to create image from an iso. This requires + suite and kernel-flavour parameters to match what is available on the iso, + obviously. + * Include hostname in default destination directory if defined + * Do not use a tmpfs by default anymore + * Place the working directory in the same directory as dest if using --tmp - + * Added --tmpfs option to specify usage of a tmpfs for the working directory + * VM specific parameters do not need to be the last ones anymore + * Unknown parameters now return an error and prints usage + * Added --overwrite for overwriting of destination directory and libvirt + domain + * Added ~/.ubuntu-vm-builder config handling + * Man page improvements and reorganization + + [Soren Hansen] + * Fix for LP: #234062 ssh root login broken + + -- Nicolas Barcet Fri, 26 May 2008 00:01:00 +0200 + +ubuntu-vm-builder (0.4ubuntu2~ppa7) hardy; urgency=low + + [ Michael Vogt ] + * patch the way do_avoid_starting_daemons() to write a policy-rc.d file in + the same way as pbuilder does (LP: #228372) + + [ Nick Barcet ] + * Added function do_copy_settings to fix bug LP: #221231 + * Fix missing ipv6 entries in host file (LP: #230299) + * Fix issue with template arguments fetching (LP: #228268) + * Create the /etc/apt/sources.list properly (LP: #218195) + * Use a tmpfs for $WORKINGDIR to avoid case when file system is mounted + with no suid (LP: #228744) + * Unproper letters variable initialization (LP: #230312) + * Option --net failed other than for Class C (LP: #232361) + + [ Loic Minier ] + * Fix v / --verbose getopt parsing. (LP: #230319) + * Compute the default ARCH with dpkg --print-architecture. (LP: #230323) + * Add support for lpia. + - Allow lpia arch, lpia and lpiacompat kernel flavours. + - Use http://ports.ubuntu.com/ubuntu-ports as default mirror for lpia. + - Update help/documentation. + * Check Release files against the archive keyring; depend on ubuntu-keyring. + (LP: #230334) + + [ Soren Hansen ] + * Fix root ssh login. (LP: #234062) + * Fix network address handling. (LP: #232361) Thanks to Kevin Traas + for the patch. + + -- Soren Hansen Fri, 23 May 2008 09:52:22 +0200 + +ubuntu-vm-builder (0.4-0ubuntu0.1) hardy-security; urgency=low + + * SECURITY UPDATE: adjust ubuntu-vm-builder to lock root account by default + + -- Nicolas Barcet Mon, 28 Apr 2008 14:02:01 +0200 + +ubuntu-vm-builder (0.4) hardy; urgency=low + + [ Soren Hansen ] + * FFe reference: (LP: #208161) + * Replace start-stop-daemon for a while to fix problems with daemons + expecting to be able to listen on certaing ports, etc. + * Unmount volatile tmpfs from lrm. + * Make /opt opt-in. + * Make default rootsize 4096 (to match documentation). + * New grub installer code. + * Fix syntax error in kernel flavour check. + * Massive refactoring. + * Make more intelligent default choices based on chosen suite, architecture, + kernel flavour, etc. + * Further quieting of the process. + + [ Nick Barcet ] + * Added template support for vmware and qemu/kvm. + * Fix a bug reported by soren where loop devices could accendentally be + overwritten. Was also preventing concurrent runs of the script. + * Further quieting of the process. + + -- Soren Hansen Wed, 02 Apr 2008 11:52:35 +0200 + +ubuntu-vm-builder (0.3) hardy; urgency=low + + * Fix perl locale warnings. + * Add missing --libvirt option. (LP: #194242) + * Add edgy to the list of supported distros (adding the appropriate quirks). + * Don't default to virtual kernel flavour when not installing i386. (LP: + #194240) + * Remove references to JeOS. (LP: #194233) + * Give more useful error messages when people pass unuseful options. + * Make the building process much less verbose (and hence less scary). + + -- Soren Hansen Wed, 12 Mar 2008 01:01:35 +0100 + +ubuntu-vm-builder (0.2) hardy; urgency=low + + * New release. + + -- Soren Hansen Thu, 21 Feb 2008 00:34:20 +0100 + +ubuntu-vm-builder (0.1) hardy; urgency=low + + * Initial upload to Ubuntu. + + -- Soren Hansen Thu, 14 Feb 2008 15:41:51 +0100 --- vm-builder-0.11.orig/debian/ubuntu-vm-builder.install +++ vm-builder-0.11/debian/ubuntu-vm-builder.install @@ -0,0 +1 @@ +ubuntu-vm-builder usr/bin --- vm-builder-0.11.orig/debian/pycompat +++ vm-builder-0.11/debian/pycompat @@ -0,0 +1 @@ +2 --- vm-builder-0.11.orig/debian/python-vm-builder.install +++ vm-builder-0.11/debian/python-vm-builder.install @@ -0,0 +1,12 @@ +debian/tmp/etc +debian/tmp/usr/bin/vmbuilder +debian/tmp/usr/lib/python*/*-packages/VMBuilder/*.py +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/*.py +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/cli +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/firstscripts +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/kvm +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/libvirt +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/postinst +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/ubuntu +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/xen +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/vmware --- vm-builder-0.11.orig/debian/python-vm-builder-ec2.install +++ vm-builder-0.11/debian/python-vm-builder-ec2.install @@ -0,0 +1 @@ +debian/tmp/usr/lib/python*/*-packages/VMBuilder/plugins/ec2 --- vm-builder-0.11.orig/debian/python-vm-builder.manpages +++ vm-builder-0.11/debian/python-vm-builder.manpages @@ -0,0 +1 @@ +vmbuilder.1 --- vm-builder-0.11.orig/debian/copyright +++ vm-builder-0.11/debian/copyright @@ -0,0 +1,28 @@ +This package was debianized by Soren Hansen on +Thu, 28 Aug 2008 05:14:27 +0200 + +It lives at https://code.launchpad.net/vmbuilder + +Copyright: + Copyright (C) 2007-2008 Canonical Ltd. + +Authors: + Soren Hansen + +License: + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +For the full license, see '/usr/share/common-licenses/GPL-3'. + +The same license and copyright applies to the Debian packaging. --- vm-builder-0.11.orig/debian/python-vm-builder.docs +++ vm-builder-0.11/debian/python-vm-builder.docs @@ -0,0 +1 @@ +html --- vm-builder-0.11.orig/debian/python-vm-builder-ec2.docs +++ vm-builder-0.11/debian/python-vm-builder-ec2.docs @@ -0,0 +1 @@ +examples --- vm-builder-0.11.orig/debian/compat +++ vm-builder-0.11/debian/compat @@ -0,0 +1 @@ +5 --- vm-builder-0.11.orig/debian/rules +++ vm-builder-0.11/debian/rules @@ -0,0 +1,20 @@ +#!/usr/bin/make -f + +DEB_PYTHON_SYSTEM = pycentral +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/python-distutils.mk + +# For when we add the extra package +#DEB_DH_INSTALL_SOURCEDIR = debian/tmp + +#makebuilddir/python-vm-builder:: +# if test -d .bzr; then if ! bzr diff -q > /dev/null; then echo 'ERROR! Uncommitted changes!!!' ; /bin/false ; fi; fi + +build/python-vm-builder:: doc-stamp + +doc-stamp: + epydoc --no-private VMBuilder + touch $@ + +cleanbuilddir/python-vm-builder:: + rm -rf html doc-stamp --- vm-builder-0.11.orig/debian/control +++ vm-builder-0.11/debian/control @@ -0,0 +1,56 @@ +Source: vm-builder +Section: utils +Priority: extra +Maintainer: Soren Hansen +Build-Depends: cdbs, debhelper (>= 5.0.38), python-all-dev (>= 2.3.5-11), python-central (>= 0.5.6), python-epydoc +Standards-Version: 3.8.0 +XS-Python-Version: >= 2.5 +Vcs-Bzr: http://bazaar.launchpad.net/~ubuntu-virt/vmbuilder/trunk + +Package: python-vm-builder +Architecture: all +Depends: kvm (>= 1:69) | qemu, debootstrap (>= 1.0.9), parted, kpartx, ubuntu-keyring, ${python:Depends}, python-cheetah, devscripts +Recommends: python-libvirt +XB-Python-Version: ${python:Versions} +Description: VM builder + Script that automates the process of creating a ready to use Linux based VM. + The currently supported hypervisors are: + . + * KVM + * Xen + * VMWare + . + The currently supported distros are: + . + * Ubuntu Dapper, Gutsy, Hardy, Intrepid, and Jaunty. + . + You can pass command line options to add extra packages, remove packages, + choose which version of Ubuntu, which mirror etc. On recent hardware + with plenty of RAM, tmpdir in /dev/shm or using a tmpfs, and a local mirror, + you can bootstrap a vm in less than a minute. + +Package: ubuntu-vm-builder +Architecture: all +Depends: python-vm-builder, ${python:Depends} +XB-Python-Version: ${python:Versions} +Description: Ubuntu VM builder + Script which automates the process of creating a ready to use VM based on + Ubuntu. You can pass command line options to add extra packages, remove + packages, choose which version of Ubuntu, which mirror to use etc. + . + On recent hardware with plenty of RAM, tmpdir in /dev/shm or using a tmpfs, + and a local mirror, you can bootstrap a vm in less than a minute. + +Package: python-vm-builder-ec2 +Architecture: all +Depends: python-vm-builder, ec2-ami-tools, python-boto, ${python:Depends} +XB-Python-Version: ${python:Versions} +Description: EC2 Ubuntu VM builder + Ubuntu vmbuilder module that automates the process of create a ready to use + EC2 image (AMI) based on Ubuntu. You can pass command line options to add + extra packages, remove packages, choose which version of Ubuntu, which + mirror to use etc. + . + VMBuilder module to build, upload and register EC2 images. You will + need to have an Amazon EC2 account in order to use this package. + --- vm-builder-0.11.orig/VMBuilder/vcsversion.py +++ vm-builder-0.11/VMBuilder/vcsversion.py @@ -0,0 +1,23 @@ +#!/usr/bin/env python +"""This file is automatically generated by generate_version_info +It uses the current working tree to determine the revision. +So don't edit it. :) +""" + +version_info = {'branch_nick': u'karmic', + 'build_date': '2009-06-23 23:30:07 +0200', + 'clean': None, + 'date': '2009-06-10 16:16:04 +0200', + 'revision_id': 'soren@canonical.com-20090610141604-a60hxl3yg9hm2lu8', + 'revno': 295} + +revisions = {} + +file_revisions = {} + + + +if __name__ == '__main__': + print 'revision: %(revno)d' % version_info + print 'nick: %(branch_nick)s' % version_info + print 'revision id: %(revision_id)s' % version_info --- vm-builder-0.11.orig/VMBuilder/disk.py +++ vm-builder-0.11/VMBuilder/disk.py @@ -23,6 +23,7 @@ import re import string import tempfile +import time import VMBuilder from VMBuilder.util import run_cmd from VMBuilder.exception import VMBuilderUserError, VMBuilderException @@ -139,7 +140,25 @@ """ Destroy all mapping devices """ + # first sleep to give the loopback devices a chance to settle down + time.sleep(3) + + tries = 0 + max_tries = 3 + while tries < max_tries: + try: + run_cmd('kpartx', '-d', self.filename, ignore_fail=False) + break + except: + pass + tries += 1 + time.sleep(3) + + if tries >= max_tries: + # try it one last time + logging.info("Could not unmount '%s' after '%d' attempts. Final attempt" % (self.filename, tries)) run_cmd('kpartx', '-d', self.filename, ignore_fail=ignore_fail) + for part in self.partitions: self.mapdev = None @@ -215,7 +234,7 @@ @rtype: string @return: the filesystem type of the partition suitable for passing to parted """ - return { TYPE_EXT2: 'ext2', TYPE_EXT3: 'ext2', TYPE_XFS: 'ext2', TYPE_SWAP: 'linux-swap' }[self.type] + return { TYPE_EXT2: 'ext2', TYPE_EXT3: 'ext2', TYPE_XFS: 'ext2', TYPE_SWAP: 'linux-swap(new)' }[self.type] def create(self, disk): """Adds partition to the disk image (does not mkfs or anything like that)""" @@ -289,7 +308,7 @@ if not self.dummy: cmd = self.mkfs_fstype() + [self.filename] run_cmd(*cmd) - self.uuid = run_cmd('vol_id', '--uuid', self.filename).rstrip() + self.uuid = run_cmd('blkid', '-s', 'UUID', '-o', 'value', self.filename).rstrip() def mkfs_fstype(self): if self.vm.suite in ['dapper', 'edgy', 'feisty', 'gutsy']: --- vm-builder-0.11.orig/VMBuilder/plugins/ubuntu/distro.py +++ vm-builder-0.11/VMBuilder/plugins/ubuntu/distro.py @@ -136,7 +136,7 @@ msg = "locale-gen does not recognize your locale '%s'" % self.vm.lang raise VMBuilderUserError(msg) - if self.vm.ec2: + if hasattr(self.vm, 'ec2') and self.vm.ec2: self.get_ec2_kernel() self.get_ec2_ramdisk()