Skip to content

Commit 7106889

Browse files
authored
Set the number of task_executor processes through the environment variable WS. (#846)
### What problem does this PR solve? ### Type of change - [x] Other (please describe): Use environment variable to control the task executor processor number.
1 parent 93b35f4 commit 7106889

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docker/entrypoint.sh

+3-1
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,16 @@
55
export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/
66

77
PY=python3
8+
if [[ -z "$WS" || $WS -lt 1 ]]; then
9+
WS=1
10+
fi
811

912
function task_exe(){
1013
while [ 1 -eq 1 ];do
1114
$PY rag/svr/task_executor.py ;
1215
done
1316
}
1417

15-
WS=1
1618
for ((i=0;i<WS;i++))
1719
do
1820
task_exe &

0 commit comments

Comments
 (0)