mirror of
https://github.com/mudler/LocalAI.git
synced 2025-05-21 01:37:54 +00:00
Using exec when starting a backend instead of spawning a new process (#2720)
Co-authored-by: Simon Siebert <ansiebert@deloitte.de>
This commit is contained in:
parent
9280060e05
commit
17608ea6aa
@ -148,13 +148,13 @@ function startBackend() {
|
|||||||
ensureVenv
|
ensureVenv
|
||||||
|
|
||||||
if [ ! -z ${BACKEND_FILE} ]; then
|
if [ ! -z ${BACKEND_FILE} ]; then
|
||||||
python ${BACKEND_FILE} $@
|
exec python ${BACKEND_FILE} $@
|
||||||
elif [ -e "${MY_DIR}/server.py" ]; then
|
elif [ -e "${MY_DIR}/server.py" ]; then
|
||||||
python ${MY_DIR}/server.py $@
|
exec python ${MY_DIR}/server.py $@
|
||||||
elif [ -e "${MY_DIR}/backend.py" ]; then
|
elif [ -e "${MY_DIR}/backend.py" ]; then
|
||||||
python ${MY_DIR}/backend.py $@
|
exec python ${MY_DIR}/backend.py $@
|
||||||
elif [ -e "${MY_DIR}/${BACKEND_NAME}.py" ]; then
|
elif [ -e "${MY_DIR}/${BACKEND_NAME}.py" ]; then
|
||||||
python ${MY_DIR}/${BACKEND_NAME}.py $@
|
exec python ${MY_DIR}/${BACKEND_NAME}.py $@
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user