Serve the CMS admin panel under /admin on the public domain
Replace the separate CMS subdomain with path-based routing in Caddy: /admin and /uploads go to Strapi, everything else to the frontend. Strapi 5 nests its whole admin panel (UI and API) under /admin, so this one prefix is enough and never collides with the frontend's own /api routes. Drops CMS_DOMAIN and the unused STRAPI_URL env var on the cms service; PUBLIC_STRAPI_URL now points at the same origin as the site. Authentication is unchanged: Strapi's own admin login still gates the panel, this only changes how it's reached.
This commit is contained in:
@@ -9,8 +9,6 @@ services:
|
||||
cms:
|
||||
ports:
|
||||
- "127.0.0.1:1337:1337"
|
||||
environment:
|
||||
STRAPI_URL: http://localhost:1337
|
||||
|
||||
frontend:
|
||||
ports:
|
||||
|
||||
Reference in New Issue
Block a user