Skip to content

[NO-JIRA] cloudbox lgtm-mono: a self-exit must not fail the unit; no failure page under the kill switch - #1070

Merged
johnnymo87 merged 1 commit into
mainfrom
lgtm-mono-execstop
Dec 2, 2026
Merged

johnnymo87 merged 1 commit into
mainfrom
lgtm-mono-execstop

Conversation

@johnnymo87

Copy link
Copy Markdown
Owner

Why

While exercising lgtm's kill-switch runbook (lgtm-oqw2.35), a start of lgtm-mono.service with the kill switch on behaved like this:

  1. run.sh exited 0, as intended.
  2. systemd then ran ExecStop=docker stop lgtm-mono, which failed with "No such container".
  3. That failure marked the unit failed. It went into a Restart=on-failure loop, and lgtm-mono-failure paged.

The page tells the reader to hand the repos back to legacy. That is the wrong advice during an incident.

What

  • ExecStop gets the - prefix. If run.sh exits by itself, there is no container to stop, and that must not fail the unit. The unit's result still comes from ExecStart's exit status.
  • The failure alert says nothing while <serviceDir>/kill-switch.json exists.

Switch impact

Only the lgtm-mono units change. The unit has restartIfChanged = false, so the switch neither restarts nor stops the running container. The new ExecStop takes effect at the unit's next start.

…ge under the kill switch

ExecStop's docker stop fails when run.sh exits by itself (no container), which turned the kill
switch's clean exit into a unit failure: a restart loop and a page whose advice (hand repos back
to legacy) is wrong mid-incident. Seen once while exercising lgtm's kill-switch runbook.
@johnnymo87 johnnymo87 changed the title [NO-JIRA] HOLD cloudbox lgtm-mono: a self-exit must not fail the unit; no failure page under the kill switch [NO-JIRA] cloudbox lgtm-mono: a self-exit must not fail the unit; no failure page under the kill switch Dec 2, 2026
@johnnymo87
johnnymo87 enabled auto-merge (squash) December 2, 2026 05:19
@johnnymo87
johnnymo87 merged commit 2010c20 into main Dec 2, 2026
2 checks passed
@johnnymo87
johnnymo87 deleted the lgtm-mono-execstop branch December 2, 2026 05:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant