Files
collectd-openstack-plugins/devstack/plugin.sh
Emma Foley ecc9a6ee9d Add devstack support
Add devstack plugin for deploying the plugin.

Change-Id: I4ecbc8e30025604eae5d159b4f2506fe3ed484ce
2016-01-18 15:49:25 +00:00

40 lines
969 B
Bash

local xtrace=$(set +o | grep xtrace)
set -o xtrace
# Initial source of lib script
source $COLLECTD_DIR/devstack/libs/collectd
case $1 in
"stack")
case $2 in
"pre-install")
# install system package
install_collectd
;;
"install")
# adapt collectd.conf
adapt_collectd_conf
;;
"post-config")
# start collectd service
start_collectd
;;
"extra")
# no-op
:
;;
esac
;;
"unstack")
# stop the service and restore original /etc/collect.conf
stop_collectd
restore_collectd_conf
;;
"clean")
# no cleaning required as of now
:
;;
esac
$xtrace