#!/bin/bash

# You can change these path by environ
# export UPLOAD_FOLDER="$(dirname "$0")/uploads"
# export PRINT_CONFIG_FOLDER="$(dirname "$0")/print_config"
# export PRUSA_SLICE_BIN="$(dirname "$0")/prusaslicer/PrusaSlicer-2.9.4-aarch64-full.AppImage"

source "$(dirname "$0")/venv/bin/activate"

# python "$(dirname "$0")/run.py" > /dev/null 2>&1
python "$(dirname "$0")/run.py"

# python -c "from run import init_admin; init_admin()" # 确保管理员初始化被执行
# gunicorn -k gthread --threads 10 -w 4 -b 0.0.0.0:5001 "run:app"
