From: Steven Dake Date: Wed, 23 May 2012 23:09:00 +0000 (-0700) Subject: Add U10 JEOS support to heat jeos_create X-Git-Tag: 2014.1~1790 X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=0cdccbd93f478244e65b3f1d74519721d6e113bf;p=openstack-build%2Fheat-build.git Add U10 JEOS support to heat jeos_create This requires oz 0.9.0 (or latest master). 0.8.0 shipped with most distros does not have customization support for Ubuntu images. fixes issue #23 Change-Id: I854aaf9657353b3fdb4768a277b527304e88ac8e Signed-off-by: Steven Dake --- diff --git a/MANIFEST.in b/MANIFEST.in index a7ed2ca1..3e981ef6 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -15,6 +15,7 @@ include heat/jeos/F16-x86_64-gold-jeos.tdl include heat/jeos/F17-x86_64-gold-jeos.tdl include heat/jeos/F16-x86_64-cfntools-jeos.tdl include heat/jeos/F17-x86_64-cfntools-jeos.tdl +include heat/jeos/U10-amd64-cfntools-jeos.tdl include heat/cfntools/cfn-init include heat/cfntools/cfn-hup include heat/cfntools/cfn-signal diff --git a/heat/jeos/U10-amd64-cfntools-jeos.tdl b/heat/jeos/U10-amd64-cfntools-jeos.tdl new file mode 100644 index 00000000..0440e365 --- /dev/null +++ b/heat/jeos/U10-amd64-cfntools-jeos.tdl @@ -0,0 +1,24 @@ + diff --git a/heat/utils.py b/heat/utils.py index 1212f0f6..d008a10d 100644 --- a/heat/utils.py +++ b/heat/utils.py @@ -112,11 +112,16 @@ def jeos_create(options, arguments, jeos_path, cfntools_path): (distro, arch, instances_str)) sys.exit(1) + src_arch = 'i386' fedora_match = re.match('F(1[6-7])', distro) if fedora_match: + if arch == 'x86_64': + src_arch = 'x86_64' version = fedora_match.group(1) iso = '%s/Fedora-%s-%s-DVD.iso' % (images_dir, version, arch) elif distro == 'U10': + if arch == 'amd64': + src_arch = 'x86_64' iso = '%s/ubuntu-10.04.3-server-%s.iso' % (images_dir, arch) else: logging.error('distro %s not supported' % distro) @@ -149,7 +154,7 @@ def jeos_create(options, arguments, jeos_path, cfntools_path): tdl_path = '/tmp/tdl' dsk_filename = '%s/%s-%s-%s-jeos.dsk' % (images_dir, distro, - arch, instance_type) + src_arch, instance_type) qcow2_filename = '%s/%s-%s-%s-jeos.qcow2' % (images_dir, distro, arch, instance_type) image_name = '%s-%s-%s' % (distro, arch, instance_type)