Add isolation debug router with deployment verification endpoint

This commit is contained in:
WhiteX 2025-06-12 21:00:57 +03:00 committed by rzmk
parent abbd5444d8
commit 0a9d0df15d
3 changed files with 20 additions and 13 deletions

View file

@ -93,15 +93,3 @@ if __name__ == "__main__":
@app.get("/")
async def root():
return {"Message": "Welcome to LearnHouse ✨"}
# Debug endpoint for deployment verification
@app.get("/debug/deployment")
async def debug_deployment():
import os
return {
"deployment_name": os.environ.get('DEPLOYMENT_NAME', 'NOT_SET'),
"cookie_domain": learnhouse_config.hosting_config.cookie_config.domain,
"api_domain": learnhouse_config.hosting_config.domain,
"database_host": learnhouse_config.database_config.sql_connection_string.split('@')[1].split('/')[0] if '@' in learnhouse_config.database_config.sql_connection_string else "unknown",
"redis_host": learnhouse_config.redis_config.redis_connection_string.split('@')[1].split(':')[0] if '@' in learnhouse_config.redis_config.redis_connection_string else "unknown"
}