# Gunicorn configuration import os # Exactly one worker: APScheduler and the Playwright run-queue live in # process memory, not a shared store — a second worker would duplicate # every scheduled job and run each rule twice. Fine for a low-traffic # single-user admin tool. workers = 1 threads = 4 worker_class = "gthread" bind = "0.0.0.0:" + os.environ.get("PORT", "5000") timeout = 120 # a rule run launches Chromium, logs in, and clicks through keepalive = 5