feat(cli-tools): update default local endpoint port to 20128
This commit is contained in:
@@ -564,7 +564,7 @@ pm2 startup
|
|||||||
```bash
|
```bash
|
||||||
docker build -t 9router .
|
docker build -t 9router .
|
||||||
docker run -d \
|
docker run -d \
|
||||||
-p 3000:3000 \
|
-p 20128:20128 \
|
||||||
-e JWT_SECRET="your-secure-secret" \
|
-e JWT_SECRET="your-secure-secret" \
|
||||||
-e INITIAL_PASSWORD="your-password" \
|
-e INITIAL_PASSWORD="your-password" \
|
||||||
-v 9router-data:/app/data \
|
-v 9router-data:/app/data \
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ export default function CLIToolsPageClient({ machineId }) {
|
|||||||
if (typeof window !== "undefined") {
|
if (typeof window !== "undefined") {
|
||||||
return window.location.origin;
|
return window.location.origin;
|
||||||
}
|
}
|
||||||
return "http://localhost:3000";
|
return "http://localhost:20128";
|
||||||
};
|
};
|
||||||
|
|
||||||
if (loading) {
|
if (loading) {
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ export default function DefaultToolCard({ toolId, tool, isExpanded, onToggle, ba
|
|||||||
: (!cloudEnabled ? "sk_9router" : "your-api-key");
|
: (!cloudEnabled ? "sk_9router" : "your-api-key");
|
||||||
|
|
||||||
// Add /v1 suffix only if not already present (DRY - avoid duplicate)
|
// Add /v1 suffix only if not already present (DRY - avoid duplicate)
|
||||||
const normalizedBaseUrl = baseUrl || "http://localhost:3000";
|
const normalizedBaseUrl = baseUrl || "http://localhost:20128";
|
||||||
const baseUrlWithV1 = normalizedBaseUrl.endsWith("/v1")
|
const baseUrlWithV1 = normalizedBaseUrl.endsWith("/v1")
|
||||||
? normalizedBaseUrl
|
? normalizedBaseUrl
|
||||||
: `${normalizedBaseUrl}/v1`;
|
: `${normalizedBaseUrl}/v1`;
|
||||||
|
|||||||
@@ -163,7 +163,7 @@ async function handleDisable(machineId, request) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Update Claude CLI settings to use local endpoint
|
// Update Claude CLI settings to use local endpoint
|
||||||
const host = request.headers.get("host") || "localhost:3000";
|
const host = request.headers.get("host") || "localhost:20128";
|
||||||
await updateClaudeSettingsToLocal(machineId, host);
|
await updateClaudeSettingsToLocal(machineId, host);
|
||||||
|
|
||||||
return NextResponse.json({
|
return NextResponse.json({
|
||||||
|
|||||||
Reference in New Issue
Block a user