File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ import { logger } from "../utilities/logger.js";
2323import { clearTmpDirs , EphemeralDirectory , getTmpDir } from "../utilities/tempDirectories.js" ;
2424import { startDevOutput } from "./devOutput.js" ;
2525import { startWorkerRuntime } from "./devSupervisor.js" ;
26- import { startMcpServer } from "./mcpServer.js" ;
26+ import { startMcpServer , stopMcpServer } from "./mcpServer.js" ;
2727
2828export type DevSessionOptions = {
2929 name : string | undefined ;
@@ -202,7 +202,7 @@ export async function startDevSession({
202202 stopBundling ?.( ) . catch ( ( error ) => { } ) ;
203203 runtime . shutdown ( ) . catch ( ( error ) => { } ) ;
204204 stopOutput ( ) ;
205- // TODO: stop MCP server
205+ stopMcpServer ( ) ;
206206 } ,
207207 } ;
208208}
Original file line number Diff line number Diff line change @@ -167,3 +167,9 @@ export const startMcpServer = async (options: {
167167 logger . info ( `Trigger.dev MCP Server is now running on port ${ options . port } ✨` ) ;
168168 } ) ;
169169} ;
170+
171+ export const stopMcpServer = ( ) => {
172+ app . server ?. close ( ( ) => {
173+ logger . info ( `Trigger.dev MCP Server is now stopped` ) ;
174+ } ) ;
175+ } ;
You can’t perform that action at this time.
0 commit comments