diff --git a/src/server/app.ts b/src/server/app.ts index ab537c5..793d765 100644 --- a/src/server/app.ts +++ b/src/server/app.ts @@ -300,9 +300,9 @@ export class AppServer { private setupWebDashboard(): void { // Resolve the web dashboard dist directory relative to this file. - // In the built output: dist/server/app.js → dist/web/ is at ../web + // tsup bundles to dist/index.js, so dist/web/ is a sibling. const thisDir = path.dirname(fileURLToPath(import.meta.url)); - const webDir = path.resolve(thisDir, '..', 'web'); + const webDir = path.resolve(thisDir, 'web'); if (!fs.existsSync(webDir)) { logger.debug({ webDir }, 'Web dashboard dist not found, skipping static mount'); @@ -319,7 +319,7 @@ export class AppServer { this.app.get('*', (req, res, next) => { // Skip API / MCP / health routes if ( - req.path.startsWith('/api') || + req.path.startsWith('/api/') || req.path.startsWith('/sse') || req.path.startsWith('/messages') || req.path === '/health'