fix: system_all_log.html ReferenceError and other updates

This commit is contained in:
2026-01-17 14:06:27 +09:00
parent cf19d79ef8
commit 2681f5a096
24 changed files with 820 additions and 141 deletions

View File

@@ -4,12 +4,21 @@
export GEVENT_NOWAITPID=1
export PYTHONWARNINGS="ignore::DeprecationWarning"
CONFIGFILE="./config.yaml"
CONFIGFILE="/data/config.yaml"
COUNT=0
# 🔧 서버 시작 전에 플러그인 업데이트
# 🌐 Camoufox 브라우저 캐시 경로 설정 (마운트된 data 폴더 사용으로 이미지 용량 절감)
export CAMOUFOX_CACHE_DIR="/data/.camoufox"
# 🔧 서버 시작 전에 플러그인 업데이트 및 브라우저 확인
update_plugins() {
PLUGINS_DIR="./data/plugins"
# Camoufox 브라우저 체크 및 다운로드 (컨테이너 최초 실행 시 1회)
if [ ! -d "$CAMOUFOX_CACHE_DIR" ]; then
echo "Fetching Camoufox binaries to $CAMOUFOX_CACHE_DIR..."
camoufox fetch
fi
PLUGINS_DIR="/data/plugins"
if [ -d "$PLUGINS_DIR" ]; then
for dir in "$PLUGINS_DIR"/*/; do
if [ -d "$dir/.git" ]; then
@@ -28,14 +37,23 @@ fi
while true;
do
python -m flaskfarm.main --repeat ${COUNT} --config ${CONFIGFILE}
echo "------------------------------------------------"
echo "Starting FlaskFarm Python Process (COUNT: ${COUNT})"
echo "Config: ${CONFIGFILE}"
echo "------------------------------------------------"
python main.py --repeat ${COUNT} --config ${CONFIGFILE}
RESULT=$?
echo "PYTHON EXIT CODE : ${RESULT}.............."
echo "------------------------------------------------"
echo "PYTHON EXIT CODE : ${RESULT}"
echo "------------------------------------------------"
if [ "$RESULT" = "1" ]; then
echo 'REPEAT....'
update_plugins # 재시작 시에도 업데이트
echo 'Restarting... (RESULT=1)'
update_plugins
else
echo 'FINISH....'
echo "Exiting... (RESULT=${RESULT})"
break
fi
COUNT=`expr $COUNT + 1`