From 7ff2e4252f6639bb4c6e9b9604c982220ec4d1f2 Mon Sep 17 00:00:00 2001 From: Emma Foley Date: Thu, 19 Jan 2017 19:50:02 +0000 Subject: [PATCH] Install collectd_ceilometer module during deployment pip_install collectd_ceilometer module - Install libvirt-* requirements from the package manager so pip can build This ensures is actually installed from teh requirements.txt file, in relation to the related bug. Change-Id: Iba26b1da863288e789f68646dee6a7f62fd6c160 Partial-Bug: #1644254 --- devstack/libs/collectd | 11 ++++++++++- devstack/plugin.sh | 4 ++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/devstack/libs/collectd b/devstack/libs/collectd index 205edfa..f5db521 100644 --- a/devstack/libs/collectd +++ b/devstack/libs/collectd @@ -17,7 +17,16 @@ function stop_collectd { fi } -# install collectd service +function install_requirements { + echo "Installing pre-resquisites" + if is_ubuntu; then + install_package libvirt-bin libvirt-dev python-libvirt + elif is_fedora; then + install_package libvirt libvirt-devel libvirt-python + fi +} + +# install collectd function install_collectd { if [[ "$COLLECTD_INSTALL" == True ]]; then if is_fedora || is_ubuntu; then diff --git a/devstack/plugin.sh b/devstack/plugin.sh index e328ca6..d8f9932 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -8,10 +8,10 @@ set -o xtrace "stack") case $2 in "pre-install") - # no-op - : + install_requirements ;; "install") + pip_install $COLLECTD_CEILOMETER_DIR # install system package install_collectd # adapt collectd.conf