[openstack-dev] Horizon customization_module feature doesn't work

Daniel McDougall daniel.mcdougall at liftoffsoftware.com
Sun Nov 11 02:50:48 UTC 2012


I am developing a Gate One (https://github.com/liftoff/GateOne/) module for
Horizon (so you can get a real terminal instead of the can't-copy-and-paste
VNC one). I've got it working great if I manually make changes to tabs.py,
tables.py, views.py, and urls.py inside of
openstack_dashboard/dashboards/project/.  This adds a tab to the 'Instance
Detail' page alongside 'Log' and 'VNC' named, 'SSH' that instantly connects
you to your instance when you click on it; providing a really nice HTML5
terminal interface for your instance (that you can, you know, copy & paste
in and out of =).

However, I don't like the idea of modifying the code in place (upgrading
Horizon would overwrite my changes).  Along these lines I tried to use the
customization_module feature described here:
http://docs.openstack.org/developer/horizon/topics/customizing.html

...but it doesn't work.  I literally copied & pasted the example and I get
nothing (the /settings/ page still shows the name as "OpenStack API").  Not
even an error message in the Apache logs or on the page.  Zero changes.
 I've restarted apache and whatnot.  Making changes to other sections of
the settings.py take effect just fine (e.g. SITE_BRANDING).  I even did
this to see if I could get it to generate an error:

HORIZON_CONFIG = {
    <all the normal stuff>,
    'customization_module': 'nonexistent.override'
}

...but I get no error from that.  Nothing at all, in fact.  The setting
doesn't appear to do anything at all.  I've tried placing the overrides.py
file all over the place.  Inside of openstack_dashboard (as
openstack_dashboard.overrides), myproject, etc etc.  No matter what I try
it seems to have no impact.

My conclusion is that this feature just plain doesn't work.  There is no
existing tests for it and despite much googling I couldn't find a single
example of it in use.  There is literally not a single .py file indexed in
Google that has 'customization_module' in it except for Horizon's on
base.py.

Maybe the customization_module feature is the wrong way to go about this;
I'm just getting started with Horizon.  Any suggestions or ideas are
appreciated.

-- 
Dan McDougall - Chief Executive Officer and Developer
Liftoff Software ✈ Your flight to the cloud is now boarding.
904-446-8323
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20121110/72d3a298/attachment.html>


More information about the OpenStack-dev mailing list