From c715a1b3c1ceb9dc2f745eb65e014912eafdf7eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Albert?= Date: Mon, 19 Oct 2015 12:21:12 +0200 Subject: [PATCH] Fixed enabled files for Liberty release We used to have only one enabled file and tricked horizon in loading all others enabled files as if it was a dashboard. This trick is not working anymore. Closes-Bug: #1507087 Change-Id: I7b075ab66d623e28efb174191ad0ebd359ec06a2 --- cloudkittydashboard/_90_enable_ck.py | 29 ------------------- .../enabled/_11_admin_hashmap_panel.py | 2 ++ contrib/cloudkitty-dashboard.spec.in | 8 +++-- 3 files changed, 7 insertions(+), 32 deletions(-) delete mode 100644 cloudkittydashboard/_90_enable_ck.py diff --git a/cloudkittydashboard/_90_enable_ck.py b/cloudkittydashboard/_90_enable_ck.py deleted file mode 100644 index dd35edb..0000000 --- a/cloudkittydashboard/_90_enable_ck.py +++ /dev/null @@ -1,29 +0,0 @@ -# Copyright 2015 Objectif Libre -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -from openstack_dashboard.utils import settings - -import cloudkittydashboard.enabled - - -ADD_INSTALLED_APPS = ['cloudkittydashboard'] -UPDATE_HORIZON_CONFIG = {} -DASHBOARD = '' - - -settings.update_dashboards( - (cloudkittydashboard.enabled,), - UPDATE_HORIZON_CONFIG, - ADD_INSTALLED_APPS -) diff --git a/cloudkittydashboard/enabled/_11_admin_hashmap_panel.py b/cloudkittydashboard/enabled/_11_admin_hashmap_panel.py index 052b9d7..4de257c 100644 --- a/cloudkittydashboard/enabled/_11_admin_hashmap_panel.py +++ b/cloudkittydashboard/enabled/_11_admin_hashmap_panel.py @@ -12,6 +12,8 @@ # License for the specific language governing permissions and limitations # under the License. +ADD_INSTALLED_APPS = ['cloudkittydashboard'] + PANEL_GROUP = 'rating' PANEL_DASHBOARD = 'admin' PANEL = 'hashmap' diff --git a/contrib/cloudkitty-dashboard.spec.in b/contrib/cloudkitty-dashboard.spec.in index 9b43c79..09cb91c 100644 --- a/contrib/cloudkitty-dashboard.spec.in +++ b/contrib/cloudkitty-dashboard.spec.in @@ -36,16 +36,18 @@ rm -rf {test-,}requirements.txt tools/{pip,test}-requires %install %{__python} setup.py install -O1 --skip-build --root=%{buildroot} mkdir -p %{buildroot}/usr/share/openstack-dashboard/openstack_dashboard/enabled/ -ln -s %{python_sitelib}/cloudkittydashboard/_90_enable_ck.py \ - %{buildroot}/usr/share/openstack-dashboard/openstack_dashboard/enabled/_90_enable_ck.py +ln -s %{python_sitelib}/cloudkittydashboard/enabled/_[0-9]*.py \ + %{buildroot}/usr/share/openstack-dashboard/openstack_dashboard/enabled/ %files %{python_sitelib}/* -/usr/share/openstack-dashboard/openstack_dashboard/enabled/_90_enable_ck.py +/usr/share/openstack-dashboard/openstack_dashboard/enabled/* %description OpenStack Rating-as-a-Service - Dashboard %changelog +* Mon Oct 19 2015 Stéphane Albert - @VERSION@ +- Updated with new enabled files * Wed May 20 2015 Gauvain Pocentek - @VERSION@ - Initial release