From 8063fee829d1e22bb7958599d8b0359846cde462 Mon Sep 17 00:00:00 2001 From: "Sean M. Collins" Date: Tue, 24 May 2016 11:27:36 -0700 Subject: [PATCH] Add neutron-metering agent and configuration This is the equivalent of the q-metering from neutron-legacy Change-Id: Ie2ad6e18cfd6f5cd9af0da30bc36a1cd27e39189 --- lib/neutron | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/neutron b/lib/neutron index fa2e926995..966bb54b81 100644 --- a/lib/neutron +++ b/lib/neutron @@ -242,6 +242,13 @@ function configure_neutron_new { iniset $NEUTRON_CONF DEFAULT ssl_key_file "$NEUTRON_SSL_KEY" fi + # Metering + if is_service_enabled neutron-metering; then + source $TOP_DIR/neutron_plugins/services/metering + neutron_agent_metering_configure_common + neutron_agent_metering_configure_agent + fi + } # configure_neutron_rootwrap() - configure Neutron's rootwrap @@ -428,6 +435,10 @@ function start_neutron_new { if is_service_enabled neutron-metadata-agent; then run_process neutron-metadata-agent "$NEUTRON_BIN_DIR/$NEUTRON_META_BINARY $NEUTRON_CONFIG_ARG" fi + + if is_service_enabled neutron-metering; then + run_process neutron-metering "$AGENT_METERING_BINARY --config-file $NEUTRON_CONF --config-file $METERING_AGENT_CONF_FILENAME" + fi } # stop_neutron() - Stop running processes (non-screen)