fix: use server.localhost subdomain for server-ui (same /assets conflict)
Server UI assets also use absolute /assets/* paths that conflict with the SPA catch-all. Same fix as Logto: Host-based routing at server.localhost gives it its own namespace. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -170,10 +170,8 @@ services:
|
|||||||
CAMELEER_API_URL: http://cameleer3-server:8081
|
CAMELEER_API_URL: http://cameleer3-server:8081
|
||||||
labels:
|
labels:
|
||||||
- traefik.enable=true
|
- traefik.enable=true
|
||||||
- traefik.http.routers.server-ui.rule=PathPrefix(`/server`)
|
- traefik.http.routers.server-ui.rule=Host(`server.${PUBLIC_HOST:-localhost}`)
|
||||||
- traefik.http.routers.server-ui.service=server-ui
|
- traefik.http.routers.server-ui.service=server-ui
|
||||||
- traefik.http.routers.server-ui.middlewares=server-ui-strip
|
|
||||||
- traefik.http.middlewares.server-ui-strip.stripprefix.prefixes=/server
|
|
||||||
- traefik.http.services.server-ui.loadbalancer.server.port=80
|
- traefik.http.services.server-ui.loadbalancer.server.port=80
|
||||||
networks:
|
networks:
|
||||||
- cameleer
|
- cameleer
|
||||||
|
|||||||
@@ -162,7 +162,7 @@ export function Layout() {
|
|||||||
<Sidebar.FooterLink
|
<Sidebar.FooterLink
|
||||||
icon={<ObsIcon />}
|
icon={<ObsIcon />}
|
||||||
label="View Dashboard"
|
label="View Dashboard"
|
||||||
onClick={() => window.open('/server/', '_blank', 'noopener')}
|
onClick={() => window.open(`http://server.${window.location.hostname}`, '_blank', 'noopener')}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
{/* User info + logout */}
|
{/* User info + logout */}
|
||||||
|
|||||||
Reference in New Issue
Block a user