Add support for enabling/disabling the Ubuntu theme

This commit is contained in:
James Page 2013-03-22 11:23:33 +00:00
parent 03a15bdec5
commit f63caae451
3 changed files with 11 additions and 1 deletions

View File

@ -74,3 +74,7 @@ options:
type: string
default: "no"
description: Show Django debug messages.
ubuntu-theme:
type: string
default: "yes"
description: Use Ubuntu theme for the dashboard.

View File

@ -3,7 +3,7 @@
CHARM="openstack-dashboard"
PACKAGES="openstack-dashboard openstack-dashboard-ubuntu-theme python-keystoneclient python-memcache memcached haproxy"
PACKAGES="openstack-dashboard python-keystoneclient python-memcache memcached haproxy"
LOCAL_SETTINGS="/etc/openstack-dashboard/local_settings.py"
if [[ -e "$CHARM_DIR/lib/openstack-common" ]] ; then

View File

@ -120,6 +120,12 @@ function config_changed {
set_or_update DEBUG True
fi
if [ "$(config-get ubuntu-theme)" != "yes" ]; then
apt-get purge openstack-dashboard-ubuntu-theme || :
else
apt-get install openstack-dashboard-ubuntu-theme
fi
# Reconfigure Apache Ports
configure_apache "80:70" "443:433"
service apache2 restart