OPC # 0002: Improvements to Client provisioning workflows
This commit is contained in:
@@ -44,6 +44,18 @@ export function streamComposeForceUp(onLine: (line: string) => void, onDone: ()
|
||||
return src;
|
||||
}
|
||||
|
||||
/**
|
||||
* Nuke & Recreate — force-removes every known platform container by name first
|
||||
* (kills orphans that --remove-orphans won't touch), then runs compose up fresh.
|
||||
* Use this when Force Recreate still fails with "container name already in use".
|
||||
*/
|
||||
export function streamComposeNuke(onLine: (line: string) => void, onDone: () => void): EventSource {
|
||||
const src = new EventSource(`${BASE_URL}/api/infra/compose/nuke/stream`);
|
||||
src.onmessage = (e) => onLine(e.data);
|
||||
src.onerror = () => { onDone(); src.close(); };
|
||||
return src;
|
||||
}
|
||||
|
||||
export function streamComposeDown(onLine: (line: string) => void, onDone: () => void): EventSource {
|
||||
const src = new EventSource(`${BASE_URL}/api/infra/compose/down/stream`);
|
||||
src.onmessage = (e) => onLine(e.data);
|
||||
|
||||
Reference in New Issue
Block a user