diff options
| author | yyamashita <yyamashita@hetzner.yyamashita.com> | 2026-07-11 20:47:49 +0900 |
|---|---|---|
| committer | yyamashita <yyamashita@hetzner.yyamashita.com> | 2026-07-11 20:47:49 +0900 |
| commit | b3066893bf14622f716f8ca5d6def845cd76e56f (patch) | |
| tree | 785006d67fcfaf902a7b22bbf75aaebf1f417264 /claude | |
| parent | 89e42d469a48fcf5e2eb54e5fc67c8a7c38fc41a (diff) | |
The `-` prefix tells systemd to ignore the exit code of tmux kill-session,
so restart succeeds even when the claude process has crashed and the session
no longer exists.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'claude')
| -rw-r--r-- | claude/systemd/claude-code@.service | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/claude/systemd/claude-code@.service b/claude/systemd/claude-code@.service index e3983b6..e85507e 100644 --- a/claude/systemd/claude-code@.service +++ b/claude/systemd/claude-code@.service @@ -7,7 +7,7 @@ Type=oneshot RemainAfterExit=yes WorkingDirectory=/home/yyamashita/workspaces/repos/%i ExecStart=/usr/bin/tmux new-session -d -s claude-%i -c /home/yyamashita/workspaces/repos/%i /usr/local/bin/claude --remote-control %i --dangerously-skip-permissions -ExecStop=/usr/bin/tmux kill-session -t claude-%i +ExecStop=-/usr/bin/tmux kill-session -t claude-%i Environment=HOME=/home/yyamashita Environment=USER=yyamashita Environment=XDG_RUNTIME_DIR=/run/user/1000 |
