drive
One master plus Distributed.jl workers. The script is a driver that farms work (e.g. pmap).
julia --project=. -m DistSSHKit drive [options] [local:N] [host:N...] SCRIPT.jl [script_args...]Also: First Steps · Demo, go, API (drive!, pipeline!), drive --help. Flag vocabulary and a short go vs drive table: User Guide.
vs go: one master plus Distributed workers; host:N is worker count. Opt-in git parity is here only (--require-git). For a plain script with no driver contract, prefer go.
Flags
| Flag | Meaning |
|---|---|
--sync | Git push/pull immediately before the run (optional; default is none; confirm unless -y) |
--rsync | Rsync deploy first (empty/missing remote, or after setup --delete) |
--require-git | Opt-in git parity: dirty-tree warn + remote commit must match local |
--require-all-hosts | Fail if a listed SSH host did not join, or if collect reported an error (default: best-effort, exit 0) |
--skip-git-guard | Compat no-op (parity already off) |
-w / --workers N | Default worker count for hosts without :N (also -w:N) |
-l / --local N | Alias for local:N (also --local:N; count, not size) |
--julia PATH | Julia on SSH workers |
--output-dir PATH | Result root → DISTRIBUTED_OUTPUT_DIR (not go batch root) |
--log-dir PATH | Log directory override |
--no-log | Do not write drive_<timestamp>.log |
--package NAME | using NAME on workers (override Project.toml name) |
--collect-missing ROOT HOST... | Collect-only: remote files absent locally |
--collect-overwrite ROOT HOST... | Collect-only: merge remote tree (overwrite same names) |
-q / --quiet | Hide terminal detail; kit log still written when logging is on |
--progress | Live status (TTY default) |
--verbose | Full detail (non-TTY default) |
-y / --yes | Auto-accept memory-pressure and other prompts |
--hosts CSV | Comma-separated worker specs (same form as CLI tokens / DISTSSHKIT_HOSTS) |
--hosts-file PATH | Append worker specs (host:N preserved) |
-v / --version | Print DistSSHKit version and exit |
-h / --help | Full help |
--sync/--rsyncare mutually exclusive (pre-run sync)--require-gitcannot combine with--rsyncor--skip-git-guard--skip-git-guardis a compat no-op (parity already off) and may combine with--sync/--rsync- Default pre-run sync and git parity are both none (same idea as
go). Prepare remotes withsetup, or pass--sync/--rsync. Use--require-gitonly on git-managed remotes.
DISTSSHKIT_REQUIRE_ALL_HOSTS=1 is the same as --require-all-hosts. DISTSSHKIT_JOBS (default 1) caps concurrent SSH host work for rsync, post-run collect, and size Julia-path detection.
Prerequisites
Run setup --check on new clusters. Remotes need the project tree and an instantiate. Prefer matching Julia major.minor.
Workers
local:N / host:N (or -w defaults). Size with size.
- Local workers are torn down with
rmprocsat the end of everydriverun - Before adding SSH workers,
drivemaypkillleftover Distributed processes on those hosts; skip withDISTSSHKIT_SKIP_GLOBAL_WORKER_PKILL=1(User Guide) - Machine-wide local kill is
setup --cleanup
Results / collect
After main(): post-run-new collect. Standalone pull via the collect flags above. See User Guide for mode names.
Collect expands remote ~/… roots on each host before find / rsync so the controller never relpaths against a tilde base (same ENV as setup remote path).
Driver script
Expects init_output_dir! / main (and optional hooks). Details and ENV: drive --help. Embed with drive! / pipeline!.