components/openstack/horizon/patches/05-disable-unsupported-bootsource.patch
changeset 3998 5bd484384122
parent 1989 ae222899e270
child 5405 66fd59fecd68
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/components/openstack/horizon/patches/05-disable-unsupported-bootsource.patch	Thu Mar 19 14:41:20 2015 -0700
@@ -0,0 +1,28 @@
+Internal patch to only enable the current supported boot source (Boot
+from Image).  This patch will not be committed upstream.
+
+--- horizon-2014.2.2/openstack_dashboard/dashboards/project/instances/workflows/create_instance.py.~1~	2014-10-16 06:20:50.000000000 -0700
++++ horizon-2014.2.2/openstack_dashboard/dashboards/project/instances/workflows/create_instance.py	2014-10-24 11:58:37.591052103 -0700
+@@ -141,22 +141,7 @@ class SetInstanceDetailsAction(workflows
+         source_type_choices = [
+             ('', _("Select source")),
+             ("image_id", _("Boot from image")),
+-            ("instance_snapshot_id", _("Boot from snapshot")),
+         ]
+-        if base.is_service_enabled(request, 'volume'):
+-            source_type_choices.append(("volume_id", _("Boot from volume")))
+-
+-            try:
+-                if api.nova.extension_supported("BlockDeviceMappingV2Boot",
+-                                                request):
+-                    source_type_choices.append(("volume_image_id",
+-                            _("Boot from image (creates a new volume)")))
+-            except Exception:
+-                exceptions.handle(request, _('Unable to retrieve extensions '
+-                                            'information.'))
+-
+-            source_type_choices.append(("volume_snapshot_id",
+-                    _("Boot from volume snapshot (creates a new volume)")))
+         self.fields['source_type'].choices = source_type_choices
+ 
+     def clean(self):