1 description "Neutron openvswitch plugin agent"
2 author "Thomas Goirand <zigo@debian.org>"
4 start on runlevel [2345]
10 mkdir -p /var/run/neutron
11 chown neutron:root /var/run/neutron
15 [ -r /usr/share/neutron-common/plugin_guess_func ] || exit 0
16 . /usr/share/neutron-common/plugin_guess_func
18 if ! [ -r /etc/neutron/neutron.conf ] ; then
19 echo "Cloud not read /etc/neutron/neutron.conf: exiting"
22 CURRENT_PLUGIN=`grep "^[ \t]*core_plugin[ \t]*=[ \t]*[._a-zA-Z0-9]*\$" /etc/neutron/neutron.conf | sed -e 's/^[ \t]*core_plugin[ \t]*=[ \t]*//'`
23 if [ -z "${CURRENT_PLUGIN}" ] ; then
24 echo "No core_plugin= value found: please set it and try again"
28 neutron_core_plugin_to_plugin_name ${CURRENT_PLUGIN}
29 neutron_plugin_ini_path ${NEUTRON_PLUGIN_NAME}
30 [ -r "$NEUTRON_PLUGIN_CONFIG" ] && CONF_ARG="--config-file $NEUTRON_PLUGIN_CONFIG"
31 [ -r /etc/default/openstack ] && . /etc/default/openstack
32 [ -r /etc/default/$UPSTART_JOB ] && . /etc/default/$UPSTART_JOB
34 [ "x$USE_SYSLOG" = "xyes" ] && DAEMON_ARGS="$DAEMON_ARGS --use-syslog"
35 [ "x$USE_LOGFILE" != "xno" ] && DAEMON_ARGS="$DAEMON_ARGS --log-file=/var/log/neutron/ovs-agent.log"
36 exec start-stop-daemon --start --chuid neutron:neutron --exec /usr/bin/neutron-openvswitch-agent -- \
37 --config-file=/etc/neutron/neutron.conf \
38 $CONF_ARG $DAEMON_ARGS