定时任务细化,签到成功页结果展示

This commit is contained in:
2026-03-18 09:19:29 +08:00
parent e514a11e62
commit 633e4249de
9 changed files with 408 additions and 577 deletions

View File

@@ -9,9 +9,9 @@ from typing import List
class Settings(BaseSettings):
"""Task Scheduler settings"""
# Celery settings
CELERY_BROKER_URL: str = os.getenv("CELERY_BROKER_URL", "redis://localhost:6379/0")
CELERY_RESULT_BACKEND: str = os.getenv("CELERY_RESULT_BACKEND", "redis://localhost:6379/0")
# Celery settings — 从环境变量 REDIS_URL 派生
CELERY_BROKER_URL: str = os.getenv("REDIS_URL", "redis://localhost:6379/0")
CELERY_RESULT_BACKEND: str = os.getenv("REDIS_URL", "redis://localhost:6379/0")
# Task execution settings
MAX_CONCURRENT_TASKS: int = int(os.getenv("MAX_CONCURRENT_TASKS", "10"))
@@ -40,5 +40,6 @@ class Settings(BaseSettings):
class Config:
case_sensitive = True
env_file = ".env"
extra = "ignore"
settings = Settings()