@@ -1122,20 +1122,15 @@ if is_service_enabled quantum; then
11221122 echo " OVS 1.4+ is required for tunneling between multiple hosts."
11231123 exit 1
11241124 fi
1125- sudo sed -i -e " s/.*enable-tunneling = .*$/enable-tunneling = $OVS_ENABLE_TUNNELING /g" /$Q_PLUGIN_CONF_FILE
1125+ sudo sed -i -e " s/.*enable_tunneling = .*$/enable_tunneling = $OVS_ENABLE_TUNNELING /g" /$Q_PLUGIN_CONF_FILE
11261126 fi
11271127fi
11281128
11291129# Quantum service (for controller node)
11301130if is_service_enabled q-svc; then
1131- # must remove this file from existing location, otherwise Quantum will prefer it
1132- if [[ -e $QUANTUM_DIR /etc/plugins.ini ]]; then
1133- # Support prior to common config
1134- Q_PLUGIN_INI_FILE=/etc/quantum/plugins.ini
1135- sudo mv $QUANTUM_DIR /etc/plugins.ini $Q_PLUGIN_INI_FILE
1136- fi
11371131 Q_CONF_FILE=/etc/quantum/quantum.conf
11381132 Q_API_PASTE_FILE=/etc/quantum/api-paste.ini
1133+ Q_POLICY_FILE=/etc/quantum/policy.json
11391134
11401135 if [[ -e $QUANTUM_DIR /etc/quantum.conf ]]; then
11411136 sudo mv $QUANTUM_DIR /etc/quantum.conf $Q_CONF_FILE
@@ -1145,6 +1140,10 @@ if is_service_enabled q-svc; then
11451140 sudo mv $QUANTUM_DIR /etc/api-paste.ini $Q_API_PASTE_FILE
11461141 fi
11471142
1143+ if [[ -e $QUANTUM_DIR /etc/policy.json ]]; then
1144+ sudo mv $QUANTUM_DIR /etc/policy.json $Q_POLICY_FILE
1145+ fi
1146+
11481147 if is_service_enabled mysql; then
11491148 mysql -u$MYSQL_USER -p$MYSQL_PASSWORD -e " DROP DATABASE IF EXISTS $Q_DB_NAME ;"
11501149 mysql -u$MYSQL_USER -p$MYSQL_PASSWORD -e " CREATE DATABASE IF NOT EXISTS $Q_DB_NAME CHARACTER SET utf8;"
@@ -1153,14 +1152,8 @@ if is_service_enabled q-svc; then
11531152 exit 1
11541153 fi
11551154
1156- # Update either configuration file with plugin or old plugin file
1157- # file checked below exists only in common config version
1158- if [[ -e $QUANTUM_DIR /quantum/tests/etc/quantum.conf.test ]]; then
1159- sudo sed -i -e " s/^core_plugin =.*$/core_plugin = $Q_PLUGIN_CLASS /g" $Q_CONF_FILE
1160- else
1161- sudo sed -i -e " s/^provider =.*$/provider = $Q_PLUGIN_CLASS /g" $Q_PLUGIN_INI_FILE
1162- fi
1163-
1155+ # Update either configuration file with plugin
1156+ sudo sed -i -e " s/^core_plugin =.*$/core_plugin = $Q_PLUGIN_CLASS /g" $Q_CONF_FILE
11641157 screen_it q-svc " cd $QUANTUM_DIR && python $QUANTUM_DIR /bin/quantum-server --config-file $Q_CONF_FILE "
11651158fi
11661159
@@ -1185,7 +1178,7 @@ if is_service_enabled q-agt; then
11851178 sudo ovs-vsctl --no-wait -- --if-exists del-br $OVS_BRIDGE
11861179 sudo ovs-vsctl --no-wait add-br $OVS_BRIDGE
11871180 sudo ovs-vsctl --no-wait br-set-external-id $OVS_BRIDGE bridge-id br-int
1188- sudo sed -i -e " s/.*local-ip = .*/local-ip = $HOST_IP /g" /$Q_PLUGIN_CONF_FILE
1181+ sudo sed -i -e " s/.*local_ip = .*/local_ip = $HOST_IP /g" /$Q_PLUGIN_CONF_FILE
11891182 AGENT_BINARY=$QUANTUM_DIR /quantum/plugins/openvswitch/agent/ovs_quantum_agent.py
11901183 elif [[ " $Q_PLUGIN " = " linuxbridge" ]]; then
11911184 # Start up the quantum <-> linuxbridge agent
0 commit comments