Renamed entrypoint_task_executor.sh entrypoint-parser.sh (#4583)

### What problem does this PR solve?

Renamed entrypoint_task_executor.sh entrypoint-parser.sh

### Type of change

- [x] Refactoring
This commit is contained in:
Zhichang Yu
2025-01-22 18:21:51 +08:00
committed by GitHub
parent 598e142c85
commit 336e5fb37f
2 changed files with 1 additions and 1 deletions

28
docker/entrypoint-parser.sh Executable file
View File

@ -0,0 +1,28 @@
#!/bin/bash
# replace env variables in the service_conf.yaml file
rm -rf /ragflow/conf/service_conf.yaml
while IFS= read -r line || [[ -n "$line" ]]; do
# Use eval to interpret the variable with default values
eval "echo \"$line\"" >> /ragflow/conf/service_conf.yaml
done < /ragflow/conf/service_conf.yaml.template
export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/
PY=python3
CONSUMER_NO_BEG=$1
CONSUMER_NO_END=$2
function task_exe(){
while [ 1 -eq 1 ]; do
$PY rag/svr/task_executor.py $1;
done
}
for ((i=CONSUMER_NO_BEG; i<CONSUMER_NO_END; i++))
do
task_exe $i &
done
wait;