@mcp-use/cli 2.12.4-canary.2 → 2.12.4

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.
@@ -1 +1 @@
1
- {"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/commands/deploy.ts"],"names":[],"mappings":"AAsKA,UAAU,aAAa;IACrB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;IAC5B,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAqlBD;;GAEG;AACH,wBAAsB,aAAa,CAAC,OAAO,EAAE,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC,CAmbzE"}
1
+ {"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../src/commands/deploy.ts"],"names":[],"mappings":"AA6KA,UAAU,aAAa;IACrB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;IAC5B,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAqlBD;;GAEG;AACH,wBAAsB,aAAa,CAAC,OAAO,EAAE,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC,CAmbzE"}
package/dist/index.cjs CHANGED
@@ -3057,6 +3057,10 @@ ${MCP_USE_DIR}
3057
3057
  }
3058
3058
 
3059
3059
  // src/commands/deploy.ts
3060
+ var GATEWAY_DOMAIN = "run.mcp-use.com";
3061
+ function buildGatewayUrl(slugOrId) {
3062
+ return `https://${slugOrId}.${GATEWAY_DOMAIN}/mcp`;
3063
+ }
3060
3064
  async function parseEnvFile(filePath) {
3061
3065
  try {
3062
3066
  const content = await import_node_fs7.promises.readFile(filePath, "utf-8");
@@ -3264,9 +3268,9 @@ function getMcpServerUrl(deployment) {
3264
3268
  if (deployment.customDomain) {
3265
3269
  return `https://${deployment.customDomain}/mcp`;
3266
3270
  } else if (deployment.serverSlug) {
3267
- return `https://${deployment.serverSlug}.mcp-use.run/mcp`;
3271
+ return buildGatewayUrl(deployment.serverSlug);
3268
3272
  } else if (deployment.serverId) {
3269
- return `https://${deployment.serverId}.mcp-use.run/mcp`;
3273
+ return buildGatewayUrl(deployment.serverId);
3270
3274
  } else {
3271
3275
  return `https://${deployment.domain}/mcp`;
3272
3276
  }
@@ -5644,7 +5648,10 @@ program.command("start").description("Start production server").option("-p, --pa
5644
5648
  };
5645
5649
  process.on("SIGINT", cleanup);
5646
5650
  process.on("SIGTERM", cleanup);
5647
- serverProc.on("exit", (code) => {
5651
+ serverProc.on("exit", async (code) => {
5652
+ if (!cleanupInProgress) {
5653
+ await cleanup();
5654
+ }
5648
5655
  process.exit(code || 0);
5649
5656
  });
5650
5657
  } catch (error) {