feat: derive POSTGRES_DB and Redis prefix from DEPLOY_STAGE for pipeline isolation
This commit is contained in:
@@ -1,7 +1,10 @@
|
||||
"""Redis key conventions and queue abstractions."""
|
||||
|
||||
import os
|
||||
|
||||
# --- Key prefixes ---
|
||||
PREFIX = "stonks"
|
||||
_STAGE = os.getenv("DEPLOY_STAGE", "")
|
||||
PREFIX = f"stonks:{_STAGE}" if _STAGE else "stonks"
|
||||
|
||||
# Distributed locks
|
||||
LOCK_PREFIX = f"{PREFIX}:lock"
|
||||
|
||||
Reference in New Issue
Block a user