components/openstack/horizon/patches/05-disable-unsupported-bootsource.patch
author david.comay@oracle.com
Fri, 09 Sep 2016 16:31:02 -0700
changeset 6878 252671ed151a
parent 6856 356aeea98c39
permissions -rw-r--r--
24617715 'mysql_storage_engine' option's help message could be improved

Internal patch to only enable the current supported boot source option (Boot
from Image).  This patch will not be committed upstream.

--- horizon-9.0.0.0rc1/openstack_dashboard/dashboards/project/instances/workflows/create_instance.py.~1~	2016-03-30 02:39:18.483954433 -0700
+++ horizon-9.0.0.0rc1/openstack_dashboard/dashboards/project/instances/workflows/create_instance.py	2016-03-30 02:41:14.550222691 -0700
@@ -154,25 +154,9 @@ class SetInstanceDetailsAction(workflows
         source_type_choices = [
             ('', _("Select source")),
             ("image_id", _("Boot from image")),
-            ("instance_snapshot_id", _("Boot from snapshot")),
         ]
-        if cinder.is_volume_service_enabled(request):
-            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
+        self.fields['source_type'].initial = source_type_choices[1][0]

     @memoized.memoized_method
     def _get_flavor(self, flavor_id):