@sanctuary-framework/mcp-server 0.5.15 → 0.5.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.cjs +20 -3
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +20 -3
- package/dist/cli.js.map +1 -1
- package/dist/index.cjs +20 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +20 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4634,7 +4634,7 @@ function generateLoginHTML(options) {
|
|
|
4634
4634
|
if (response.ok) {
|
|
4635
4635
|
const data = await response.json();
|
|
4636
4636
|
sessionStorage.setItem('authToken', token);
|
|
4637
|
-
window.location.href = '/
|
|
4637
|
+
window.location.href = '/'; // Dashboard is served at root path
|
|
4638
4638
|
} else if (response.status === 401) {
|
|
4639
4639
|
showError('Invalid token. Please check and try again.');
|
|
4640
4640
|
} else {
|
|
@@ -7571,7 +7571,24 @@ var DashboardApprovalChannel = class {
|
|
|
7571
7571
|
}
|
|
7572
7572
|
resolve();
|
|
7573
7573
|
});
|
|
7574
|
-
this.httpServer.on("error",
|
|
7574
|
+
this.httpServer.on("error", (err) => {
|
|
7575
|
+
if (err.code === "EADDRINUSE") {
|
|
7576
|
+
const port = this.config.port;
|
|
7577
|
+
process.stderr.write(
|
|
7578
|
+
`
|
|
7579
|
+
\u2554\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2557
|
|
7580
|
+
\u2551 Port ${port} is already in use. \u2551
|
|
7581
|
+
\u2551 \u2551
|
|
7582
|
+
\u2551 Another Sanctuary Dashboard may still be running. \u2551
|
|
7583
|
+
\u2551 To fix: lsof -ti:${port} | xargs kill \u2551
|
|
7584
|
+
\u2551 Then restart the dashboard. \u2551
|
|
7585
|
+
\u255A\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u255D
|
|
7586
|
+
|
|
7587
|
+
`
|
|
7588
|
+
);
|
|
7589
|
+
}
|
|
7590
|
+
reject(err);
|
|
7591
|
+
});
|
|
7575
7592
|
});
|
|
7576
7593
|
}
|
|
7577
7594
|
/**
|
|
@@ -7851,7 +7868,7 @@ var DashboardApprovalChannel = class {
|
|
|
7851
7868
|
if (!this.checkAuth(req, url, res)) return;
|
|
7852
7869
|
if (!this.checkRateLimit(req, res, "general")) return;
|
|
7853
7870
|
try {
|
|
7854
|
-
if (method === "GET" && url.pathname === "/") {
|
|
7871
|
+
if (method === "GET" && (url.pathname === "/" || url.pathname === "/dashboard")) {
|
|
7855
7872
|
this.serveDashboard(res);
|
|
7856
7873
|
} else if (method === "GET" && url.pathname === "/events") {
|
|
7857
7874
|
this.handleSSE(req, res);
|