Emilien Macchi | 40546f7 | 2013-09-24 15:10:25 +0200 | [diff] [blame] | 1 | # Neutron metering plugin |
| 2 | # --------------------------- |
| 3 | |
| 4 | # Save trace setting |
| 5 | MY_XTRACE=$(set +o | grep xtrace) |
| 6 | set +o xtrace |
| 7 | |
| 8 | |
| 9 | AGENT_METERING_BINARY="$NEUTRON_BIN_DIR/neutron-metering-agent" |
| 10 | METERING_PLUGIN="neutron.services.metering.metering_plugin.MeteringPlugin" |
| 11 | |
| 12 | function neutron_agent_metering_configure_common() { |
Isaku Yamahata | 9e136b4 | 2013-12-16 15:52:03 +0900 | [diff] [blame] | 13 | _neutron_service_plugin_class_add $METERING_PLUGIN |
Emilien Macchi | 40546f7 | 2013-09-24 15:10:25 +0200 | [diff] [blame] | 14 | } |
| 15 | |
| 16 | function neutron_agent_metering_configure_agent() { |
| 17 | METERING_AGENT_CONF_PATH=/etc/neutron/services/metering |
| 18 | mkdir -p $METERING_AGENT_CONF_PATH |
| 19 | |
| 20 | METERING_AGENT_CONF_FILENAME="$METERING_AGENT_CONF_PATH/metering_agent.ini" |
| 21 | |
| 22 | cp $NEUTRON_DIR/etc/metering_agent.ini $METERING_AGENT_CONF_FILENAME |
| 23 | } |
| 24 | |
Akihiro Motoki | edddb1f | 2013-12-09 20:21:06 +0900 | [diff] [blame] | 25 | function neutron_metering_stop() { |
| 26 | : |
| 27 | } |
| 28 | |
Emilien Macchi | 40546f7 | 2013-09-24 15:10:25 +0200 | [diff] [blame] | 29 | # Restore xtrace |
| 30 | $MY_XTRACE |