fix(hetzner): add SPAWN_CUSTOM guard to promptServerType (#2065)

Every other cloud provider (GCP, DO, Daytona) gates their size/type
picker behind SPAWN_CUSTOM !== "1" so users get a fast default launch.
Hetzner's promptLocation had the guard but promptServerType was missing
it, causing an unexpected interactive picker on the cheapest/most-used
cloud when running without --custom.

Bump CLI to 0.11.19.

Agent: team-lead

Co-authored-by: B <6723574+louisgv@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
A 2026-03-01 09:41:32 -08:00 committed by GitHub
parent 902f3091d3
commit 631722151c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 6 additions and 3 deletions

View file

@ -124,10 +124,9 @@ describe("Hetzner --custom prompts", () => {
restoreEnv("HETZNER_LOCATION", savedLocation);
});
it("promptServerType should return default in non-interactive mode", async () => {
it("promptServerType should return default without --custom", async () => {
delete process.env.HETZNER_SERVER_TYPE;
delete process.env.SPAWN_CUSTOM;
process.env.SPAWN_NON_INTERACTIVE = "1";
const { promptServerType, DEFAULT_SERVER_TYPE } = await import("../hetzner/hetzner");
const result = await promptServerType();
expect(result).toBe(DEFAULT_SERVER_TYPE);

View file

@ -347,6 +347,10 @@ export async function promptServerType(): Promise<string> {
return process.env.HETZNER_SERVER_TYPE;
}
if (process.env.SPAWN_CUSTOM !== "1") {
return DEFAULT_SERVER_TYPE;
}
if (process.env.SPAWN_NON_INTERACTIVE === "1") {
return DEFAULT_SERVER_TYPE;
}