* Wait for Coder workspace startup scripts to complete. * Runs `coder ssh --wait=yes -- true` and streams output.
(
workspaceName: string,
abortSignal?: AbortSignal
)
| 1251 | * Runs `coder ssh <workspace> --wait=yes -- true` and streams output. |
| 1252 | */ |
| 1253 | async *waitForStartupScripts( |
| 1254 | workspaceName: string, |
| 1255 | abortSignal?: AbortSignal |
| 1256 | ): AsyncGenerator<string, void, unknown> { |
| 1257 | log.debug("Waiting for Coder startup scripts", { workspaceName }); |
| 1258 | yield* streamCoderCommand( |
| 1259 | ["ssh", workspaceName, "--wait=yes", "--", "true"], |
| 1260 | "coder ssh --wait failed", |
| 1261 | abortSignal, |
| 1262 | "Coder startup script wait aborted" |
| 1263 | ); |
| 1264 | } |
| 1265 | |
| 1266 | /** |
| 1267 | * Create a new Coder workspace. Yields build log lines as they arrive. |