MCPcopy Create free account
hub / github.com/cameri/nostream / createPortOverrideComposeFile

Function createPortOverrideComposeFile

src/cli/utils/docker.ts:34–47  ·  view source on GitHub ↗
(port: number)

Source from the content-addressed store, hash-verified

32}
33
34export const createPortOverrideComposeFile = (port: number): string => {
35 const tempFile = join(os.tmpdir(), `nostream-port-override-${process.pid}-${Date.now()}.yml`)
36 const content = [
37 'services:',
38 ' nostream:',
39 ' environment:',
40 ` RELAY_PORT: ${port}`,
41 ' ports:',
42 ` - 127.0.0.1:${port}:${port}`,
43 ].join('\n')
44
45 fs.writeFileSync(tempFile, content, { encoding: 'utf-8' })
46 return tempFile
47}

Callers 2

docker.spec.tsFile · 0.90
runStartFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected