MCPcopy Index your code
hub / github.com/devcontainers/cli / devContainerDown

Function devContainerDown

src/test/testUtils.ts:105–112  ·  view source on GitHub ↗
(options: { containerId?: string | null; composeProjectName?: string | null; doNotThrow?: boolean })

Source from the content-addressed store, hash-verified

103 return { outcome, containerId, composeProjectName, stderr: res.stderr };
104}
105export async function devContainerDown(options: { containerId?: string | null; composeProjectName?: string | null; doNotThrow?: boolean }) {
106 if (options.containerId) {
107 await shellExec(`docker rm -f ${options.containerId}`, undefined, undefined, options.doNotThrow);
108 }
109 if (options.composeProjectName) {
110 await shellExec(`docker compose --project-name ${options.composeProjectName} down`, undefined, undefined, options.doNotThrow);
111 }
112}
113export async function devContainerStop(options: { containerId?: string | null; composeProjectName?: string | null }) {
114 if (options.containerId) {
115 await shellExec(`docker stop ${options.containerId}`);

Callers 8

updateUID.test.tsFile · 0.90
describeTests1Function · 0.90
describeTests2Function · 0.90
cli.test.tsFile · 0.90
cli.up.test.tsFile · 0.90
e2e.test.tsFile · 0.90

Calls 1

shellExecFunction · 0.85

Tested by

no test coverage detected