Properly tear down zun-api at wsgi mode

If wsgi mode is enabled, zun-api should be disabled in apache,
otherwise shutdown the process as before.

Change-Id: I33979a5454a3d68415fcfff01e9de6e99f8b31d6
This commit is contained in:
Hongbin Lu 2017-03-27 21:31:04 -05:00
parent 2ce580f97b
commit 48c57fa33f

View File

@ -462,9 +462,14 @@ function stop_zun {
if is_service_enabled zun-etcd; then
stop_zun_etcd
fi
for serv in zun-api zun-compute; do
stop_process $serv
done
if [ "$ZUN_USE_MOD_WSGI" == "True" ]; then
disable_apache_site zun
restart_apache_server
else
stop_process zun-api
fi
stop_process zun-compute
}
# Restore xtrace