Fixed Horizon static file compression in devstack
Static files needs to be compressed in Horizon. Since CloudKitty is loaded as a devstack plugin its files are copied after Horizon initialization. This patch add calls to django-admin to process new files. Change-Id: I51b703f682b74a35a1fb6cad64856093011ee2e2
This commit is contained in:
parent
fbd8efef30
commit
91b6216976
@ -208,11 +208,28 @@ function install_cloudkitty_dashboard {
|
||||
setup_dev_lib "cloudkitty-dashboard"
|
||||
}
|
||||
|
||||
# update_horizon_static() - Update Horizon static files with CloudKitty's one
|
||||
function update_horizon_static {
|
||||
# Code taken from Horizon lib
|
||||
# Setup alias for django-admin which could be different depending on distro
|
||||
local django_admin
|
||||
if type -p django-admin > /dev/null; then
|
||||
django_admin=django-admin
|
||||
else
|
||||
django_admin=django-admin.py
|
||||
fi
|
||||
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings \
|
||||
$django_admin collectstatic --noinput
|
||||
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings \
|
||||
$django_admin compress --force
|
||||
restart_apache_server
|
||||
}
|
||||
|
||||
# configure_cloudkitty_dashboard() - Set config files, create data dirs, etc
|
||||
function configure_cloudkitty_dashboard {
|
||||
sudo ln -s $CLOUDKITTY_ENABLED_DIR/_[0-9]*.py \
|
||||
$CLOUDKITTY_HORIZON_ENABLED_DIR/
|
||||
restart_apache_server
|
||||
update_horizon_static
|
||||
}
|
||||
|
||||
if is_service_enabled ck-api; then
|
||||
|
Loading…
Reference in New Issue
Block a user