Repository navigation
Commit a5ce3c4
fix(site): actually run the plan's commands, instead of skipping them silently (#250)
`serveCommand` defaulted `runner` to null, and the execution loop was:
else if (step.kind === "run" && runner) { ... }
The CLI calls `serveCommand(rest)` with no deps, so every `run` step was
skipped — in silence — and the command then printed "is live on this
machine". `nginx -t` never validated anything and `systemctl reload`
never reloaded, so the file just written was not the config being served.
That stays invisible until somebody reloads nginx for an unrelated reason,
hours or a reboot later, at which point the failure has no obvious cause.
--tls turned it from misleading into broken: the openssl step is what
creates the key, so the config was written referencing a certificate that
never existed. nginx then refuses to load the whole config — every site on
the box, not just the new one:
[emerg] cannot load certificate "/etc/ssl/moshpit/2600.crt"
Three fixes:
- a real default runner, so the plan runs
- a missing runner is a failure, not a skip: nothing takes effect, and
saying otherwise is the bug above
- a failed command prints the first line of its stderr, which is the whole
diagnosis — "nginx -t failed" without it costs an hour
Also fixes the display printing `publish-pin undefined`: that step has no
`path`, so it shows the ending instead.
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>1 parent 48796b4 commit a5ce3c4
2 files changed
Lines changed: 82 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
351 | 351 | | |
352 | 352 | | |
353 | 353 | | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
354 | 373 | | |
355 | | - | |
| 374 | + | |
356 | 375 | | |
357 | 376 | | |
358 | 377 | | |
| |||
406 | 425 | | |
407 | 426 | | |
408 | 427 | | |
409 | | - | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
410 | 433 | | |
411 | 434 | | |
412 | 435 | | |
| |||
424 | 447 | | |
425 | 448 | | |
426 | 449 | | |
427 | | - | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
428 | 457 | | |
429 | 458 | | |
430 | 459 | | |
| 460 | + | |
431 | 461 | | |
432 | 462 | | |
433 | 463 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
243 | 243 | | |
244 | 244 | | |
245 | 245 | | |
| 246 | + | |
| 247 | + | |
246 | 248 | | |
247 | 249 | | |
248 | 250 | | |
| |||
331 | 333 | | |
332 | 334 | | |
333 | 335 | | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
0 commit comments