f5e30abcc5
This allows us to configure neutron when running the rally job in the gate. This effort stems from patch [1]. Blame Kevin for not wanting to squash the two together. [1] I12aaf6121b677e9696131601b3539a7091e2858c Change-Id: I006957784ac7900021bcfee57cbc83b5a6c533c4
70 lines
2.1 KiB
Bash
70 lines
2.1 KiB
Bash
LIBDIR=$DEST/neutron/devstack/lib
|
|
|
|
source $LIBDIR/dns
|
|
source $LIBDIR/flavors
|
|
source $LIBDIR/l2_agent
|
|
source $LIBDIR/l2_agent_sriovnicswitch
|
|
source $LIBDIR/ml2
|
|
source $LIBDIR/qos
|
|
source $LIBDIR/ovs
|
|
source $LIBDIR/rally
|
|
source $LIBDIR/trunk
|
|
|
|
Q_BUILD_OVS_FROM_GIT=$(trueorfalse False Q_BUILD_OVS_FROM_GIT)
|
|
|
|
if [ -f $LIBDIR/${Q_AGENT}_agent ]; then
|
|
source $LIBDIR/${Q_AGENT}_agent
|
|
fi
|
|
|
|
if [[ "$1" == "stack" ]]; then
|
|
case "$2" in
|
|
install)
|
|
if is_service_enabled q-flavors; then
|
|
configure_flavors
|
|
fi
|
|
if is_service_enabled q-qos; then
|
|
configure_qos
|
|
fi
|
|
if is_service_enabled q-trunk; then
|
|
configure_trunk_extension
|
|
fi
|
|
if is_service_enabled q-dns; then
|
|
configure_dns_extension
|
|
fi
|
|
if [[ "$Q_AGENT" == "openvswitch" ]] && \
|
|
[[ "$Q_BUILD_OVS_FROM_GIT" == "True" ]]; then
|
|
remove_ovs_packages
|
|
compile_ovs True /usr /var
|
|
start_new_ovs
|
|
fi
|
|
;;
|
|
post-config)
|
|
if is_service_enabled q-dns; then
|
|
post_config_dns_extension
|
|
fi
|
|
if is_service_enabled q-agt; then
|
|
configure_l2_agent
|
|
fi
|
|
#Note: sriov agent should run with OVS or linux bridge agent
|
|
#because they are the mechanisms that bind the DHCP and router ports.
|
|
#Currently devstack lacks the option to run two agents on the same node.
|
|
#Therefore we create new service, q-sriov-agt, and the q-agt should be OVS
|
|
#or linux bridge.
|
|
if is_service_enabled q-sriov-agt; then
|
|
configure_$Q_PLUGIN
|
|
configure_l2_agent
|
|
configure_l2_agent_sriovnicswitch
|
|
fi
|
|
;;
|
|
extra)
|
|
if is_service_enabled q-sriov-agt; then
|
|
start_l2_agent_sriov
|
|
fi
|
|
;;
|
|
esac
|
|
elif [[ "$1" == "unstack" ]]; then
|
|
if is_service_enabled q-sriov-agt; then
|
|
stop_l2_agent_sriov
|
|
fi
|
|
fi
|