File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7979
8080import os
8181from dotenv import load_dotenv
82+ # Import at top of file
83+ from auth import JWTAuthManager
84+
85+
8286
8387load_dotenv ()
8488
@@ -145,6 +149,15 @@ class Config:
145149 max_http_buffer_size = Config .MAX_CONTENT_LENGTH
146150)
147151
152+ # Add after socketio initialization
153+ jwt_manager = JWTAuthManager (
154+ secret_key = Config .SECRET_KEY ,
155+ access_token_expiry = 3600 ,
156+ refresh_token_expiry = 604800
157+ )
158+ jwt_manager .init_auth_endpoints (app )
159+ app .config ['JWT_MANAGER' ] = jwt_manager
160+
148161
149162# DATABASE CONNECTION POOL
150163
Original file line number Diff line number Diff line change 22builder = " nixpacks"
33
44[deploy ]
5- startCommand = " gunicorn -w 2 app:app --bind 0.0.0.0:$PORT"
5+ startCommand = " gunicorn --worker-class eventlet -w 1 app:app --bind 0.0.0.0:$PORT"
66restartPolicyType = " on_failure"
7- restartPolicyMaxRetries = 10
7+ restartPolicyMaxRetries = 10
You can’t perform that action at this time.
0 commit comments