Merge "Refactor lib/neutron rootwrap conf for reuse"

This commit is contained in:
Jenkins 2015-02-04 03:50:29 +00:00 committed by Gerrit Code Review
commit fb468cb32e

@ -791,15 +791,20 @@ function cleanup_neutron {
done
}
# _configure_neutron_common()
# Set common config for all neutron server and agents.
# This MUST be called before other ``_configure_neutron_*`` functions.
function _configure_neutron_common {
function _create_neutron_conf_dir {
# Put config files in ``NEUTRON_CONF_DIR`` for everyone to find
if [[ ! -d $NEUTRON_CONF_DIR ]]; then
sudo mkdir -p $NEUTRON_CONF_DIR
fi
sudo chown $STACK_USER $NEUTRON_CONF_DIR
}
# _configure_neutron_common()
# Set common config for all neutron server and agents.
# This MUST be called before other ``_configure_neutron_*`` functions.
function _configure_neutron_common {
_create_neutron_conf_dir
cp $NEUTRON_DIR/etc/neutron.conf $NEUTRON_CONF