automated update: 2026-06-10 22:00:38

This commit is contained in:
root
2026-06-10 22:00:38 -04:00
parent a4129615df
commit 9307efef05
+6 -19
View File
@@ -2,29 +2,16 @@
set -e
export PYTHONUNBUFFERED=1
check_models() {
echo "📦 Checking models..."
# Paths updated to point to persistent root /models
if [ -d "/models/.insightface/models/buffalo_l" ]; then
echo " ✅ InsightFace Buffalo_L: present"
else
echo " ⬇️ InsightFace Buffalo_L: downloading..."
fi
echo "🚀 Starting if-curator..."
}
# 1. Run the job immediately on startup
echo "▶ Running on startup..."
uv run python -m if_curator.cli
AUTO="${AUTO_MODE:-false}"
if [ "$AUTO" != "true" ] && [ ! -t 0 ]; then
echo "❌ AUTO_MODE must be true for non-interactive execution."
exit 1
fi
check_models
# 2. If a schedule exists, start the scheduler
if [ -n "${CRON_SCHEDULE:-}" ]; then
echo "▶ CRON_SCHEDULE set to: $CRON_SCHEDULE"
echo "▶ Switching to scheduled mode..."
exec uv run python3 /app/scheduler.py
else
echo "▶ Running once..."
uv run python -m if_curator.cli
echo "▶ No schedule set, exiting."
fi