[pkg-eucalyptus-commits] [SCM] managing cloud instances for Eucalyptus branch, master, updated. 3.0.0-alpha3-257-g1da8e3a

Garrett Holmstrom gholms at fedoraproject.org
Sun Jun 16 02:31:11 UTC 2013


The following commit has been merged in the master branch:
commit 479ee9d03eb87afac13878919b4677ec0ed81bd9
Author: Garrett Holmstrom <gholms at fedoraproject.org>
Date:   Fri Apr 26 18:28:21 2013 -0700

    Make sure eustore-install-image doesn't bundle the same thing twice

diff --git a/euca2ools/commands/eustore/installimage.py b/euca2ools/commands/eustore/installimage.py
index 0034ba8..9cb14bc 100644
--- a/euca2ools/commands/eustore/installimage.py
+++ b/euca2ools/commands/eustore/installimage.py
@@ -282,11 +282,13 @@ class InstallImage(EuStoreRequest, FileTransferProgressBarMixin):
                 hv_type_dir = self.args['hypervisor'] + '-kernel'
                 hv_prefix = os.path.join(commonprefix, hv_type_dir)
             # Get any kernel and ramdisk images we're missing
+            bundled_images = []
             for member in members:
                 if member.name.startswith(hv_prefix):
                     if kernel_id is None and 'vmlinu' in member.name:
                         # Note that vmlinux/vmlinuz is not always at the
                         # beginning of the file name
+                        bundled_images.append(member.name)
                         kernel_image = self.extract_without_path(
                             tarball, member, workdir, 'Extracting kernel ')
                         manifest_loc = self.bundle_and_upload_image(
@@ -303,6 +305,7 @@ class InstallImage(EuStoreRequest, FileTransferProgressBarMixin):
                     elif (ramdisk_id is None and
                           any(s in member.name for s in ('initrd', 'initramfs',
                                                          'loader'))):
+                        bundled_images.append(member.name)
                         ramdisk_image = self.extract_without_path(
                             tarball, member, workdir, 'Extracting ramdisk')
                         manifest_loc = self.bundle_and_upload_image(
@@ -324,7 +327,10 @@ class InstallImage(EuStoreRequest, FileTransferProgressBarMixin):
             # machine image
             machine_id = None
             for member in members:
+                if member.name in bundled_images:
+                    continue
                 if machine_id is None and member.name.endswith('.img'):
+                    bundled_images.append(member.name)
                     machine_image = self.extract_without_path(
                         tarball, member, workdir, 'Extracting image  ')
                     manifest_loc = self.bundle_and_upload_image(machine_image,

-- 
managing cloud instances for Eucalyptus



More information about the pkg-eucalyptus-commits mailing list