diff options
author | QiLiang <liangqi1@huawei.com> | 2016-10-20 01:52:15 +0800 |
---|---|---|
committer | qi liang <liangqi1@huawei.com> | 2016-11-28 07:43:01 +0000 |
commit | cb6908f2a87a728e0e2c6c2b0046cd8a18837d0e (patch) | |
tree | 4abb1ffccf0a61ec153eb52efd2bf5c66ee46699 /deploy/compass_vm.sh | |
parent | b212b7ac454fea642d7637e7489ff69665e54289 (diff) |
Make openstack dashboard theme configurable
Use flag ENABLE_UBUNTU_THEME to configure enable or disable ubuntu
dashboard theme.
Set default to use ubuntu theme.
JIRA: -
Change-Id: I454c69b0290084c244979bb86c733a03721481cb
Signed-off-by: QiLiang <liangqi1@huawei.com>
(cherry picked from commit 065813ecbe8b4860da4281b6d67104798e3a8d43)
Diffstat (limited to 'deploy/compass_vm.sh')
-rwxr-xr-x | deploy/compass_vm.sh | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/deploy/compass_vm.sh b/deploy/compass_vm.sh index 0c213e31..63c1998b 100755 --- a/deploy/compass_vm.sh +++ b/deploy/compass_vm.sh @@ -48,6 +48,29 @@ function install_compass() { fi } +function exec_cmd_on_compass() { + ssh $ssh_args root@$MGMT_IP "$@" +} + +function _inject_dashboard_conf() { + if [[ "$ENABLE_UBUNTU_THEME" == "true" ]]; then + cmd=" + sed -i '/enable_ubuntu_theme/d' /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl; \ + echo enable_ubuntu_theme: True >> /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl + " + else + cmd=" + sed -i '/enable_ubuntu_theme/d' /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl; \ + echo enable_ubuntu_theme: False >> /etc/compass/templates/ansible_installer/openstack_mitaka/vars/HA-ansible-multinodes.tmpl + " + fi + exec_cmd_on_compass $cmd +} + +function inject_compass_conf() { + _inject_dashboard_conf +} + function wait_ok() { set +x log_info "wait_compass_ok enter" |