pks agentics runner stop

beta

Kill the remote tmux session of a runner handed off to an SSH target, stopping that runner daemon immediately and without a confirmation prompt.

Author: Poul Kjeldager
Usage: pks agentics runner stop [TARGET] [options]
Platform: linuxmacoswindows
Category: infrastructure

Examples

$ pks agentics runner stop hetzner

Stop the remote runner on a target

$ pks agentics runner stop hetzner --project myorg/myproject

Disambiguate when several projects share a target

runner stop ends a runner that was handed off to an SSH target by killing its remote tmux session. It stops the daemon and nothing else — containers and volumes the runner created stay where they are.

1. Prerequisites

  • A completed SSH handoff for the project you want to stop.
  • SSH reachability to the target and tmux running on it.

2. Stop the runner

pks agentics runner stop hetzner

There is no confirmation prompt — the session is killed immediately. Target and project resolution match runner status: omitting TARGET auto-selects the only registered target or opens an interactive picker when more than one is registered, and --project is required when several projects share the target.

pks agentics runner stop hetzner --project myorg/myproject

3. Verify

pks agentics runner status hetzner

The session should report as exited.

4. Clean up the remote machine

Stopping the session leaves any devcontainers the runner spawned behind. Run pks agentics runner cleanup on the remote machine separately when you want them gone.

Options

FlagDescription
--project <owner-project>Disambiguate when more than one project was handed off to this target.
-v, --verboseEnable verbose output.

Argument

ArgumentRequiredDescription
TARGETnoSSH target label or host. Auto-selected when only one target is registered; an interactive picker is shown otherwise.

Troubleshooting

  • Exit code 1 with a failure message. Either the target is unreachable or the session was already stopped. The two cases are not distinguished in the output — check reachability with a plain ssh first, then confirm with runner status.
  • "No project has been handed off to <target>". No local registration records this target. Nothing to stop there.
  • Jobs still appear to run after stopping. A container the runner spawned may still be alive. Clean up on the remote machine.

See also