fix: route people.* to frontend; path-route API/admin/oauth2 to backend
people.* now routes / to people-frontend (nginx/React SPA). Path prefixes /api/, /admin/, and /o/ are forwarded to people-backend (Django/gunicorn), matching the app's URL structure. Previously all people.* traffic hit people-backend directly, causing Django to return 404 "Page not found at /" for the root path. The [[routes.paths]] mechanism already existed in the proxy (used by the auth route) — only a config update was needed.
This commit is contained in:
@@ -62,7 +62,20 @@ data:
|
||||
|
||||
[[routes]]
|
||||
host_prefix = "people"
|
||||
backend = "http://people-backend.lasuite.svc.cluster.local:80"
|
||||
backend = "http://people-frontend.lasuite.svc.cluster.local:80"
|
||||
|
||||
# Backend handles the API, Django admin, and OAuth2 provider.
|
||||
[[routes.paths]]
|
||||
prefix = "/api/"
|
||||
backend = "http://people-backend.lasuite.svc.cluster.local:80"
|
||||
|
||||
[[routes.paths]]
|
||||
prefix = "/admin/"
|
||||
backend = "http://people-backend.lasuite.svc.cluster.local:80"
|
||||
|
||||
[[routes.paths]]
|
||||
prefix = "/o/"
|
||||
backend = "http://people-backend.lasuite.svc.cluster.local:80"
|
||||
|
||||
[[routes]]
|
||||
host_prefix = "find"
|
||||
|
||||
Reference in New Issue
Block a user