Skip to content

The tack command ​

tack plans, runs and reads runs. tack <command> --help and man tack-<command> hold the full text of each command, and this page lists them.

CommandDoes
tack plan -f WORKLOAD --to SITE [--mode planned|site-loss]Prints every step and change of a run, and changes nothing.
tack run -f WORKLOAD --to SITE [--mode planned|site-loss]Starts a run: hold Flux, switch the primary, commit to Git, release. It prints the plan and asks for the workload's name first.
tack resume RUN (-f WORKLOAD | --context CONTEXT)Continues a run from its ledger.
tack status [RUN] (-f WORKLOAD | --context CONTEXT)Shows runs and their steps from the ledger.
tack abandon RUN (-f WORKLOAD | --context CONTEXT)Marks a run that must never go on (Abandon a run).
tack prune -f WORKLOAD --keep NDeletes the ledgers of old runs that succeeded, keeping the N newest.
tack completion bash|zsh|fish|powershellPrints a shell completion script, and contacts nothing (Shell completion).

Flags ​

FlagCommandsDoes
--kubeconfig FILEevery commandthe kubeconfig holding every site's context. Default: the standard kubeconfig loading rules.
-f, --file WORKLOADevery command but completionthe Workload file. resume, status and abandon then search every site of the workload for its runs.
--to SITEplan, runthe site that becomes primary
--from SITEplan, runthe site of the current primary. Default: the primary that the --to site declares.
--mode planned|site-lossplan, runplanned, the default: the old primary demotes and hands over its token. site-loss: promote without a token after the old site is lost.
--accept-behindplan, runwith --mode site-loss: promote the target although another site that answers holds WAL past it. That site then needs a rebuild.
-o, --output text|yaml|jsonplan, statusfor plan, yaml or json print the SiteFailover the run would create
--yesrun, resume, abandon, pruneskip the confirmation. Only when a human approved this run.
--take-over RUNruntake over the holds of this earlier run, which can no longer finish. Repeat it for each run.
--forcerun with --take-over, abandongo on although a tack process may still run the run: its lease is fresh, or its ledger was just written. Only once a human checked that none does.
--fence SITEresumedemote this site although it answers as primary. Repeatable.
--accept-git-head SHAresumeaccept this commit, pushed during the run, as the run's new Git base
--context CONTEXTresume, status, abandona kube context to read runs from, instead of --file
--namespace NAMESPACEresume, status, abandonthe ledger namespace, with --context. Default: tack-system.
--reason TEXTabandonwhy the run is abandoned, recorded in its ledger
--keep Nprunekeep this many of the newest runs that succeeded, 1 or more
--skilltackprint a guide for AI agents as a skill document, and exit
-v, --versiontackprint the version

The decision flags say when to pass --fence, --accept-git-head and --take-over.

Exit codes ​

CodeMeans
0success
1error
2usage error
3the run stopped and waits for the operator (see tack status)
4the run waits for something outside it, such as Git (tack resume later)

Rules for AI agents ​

tack --help and tack --skill hold these rules:

  • An agent never starts tack run or tack resume without an explicit instruction from a human for that run.
  • tack plan comes first. Show its output to the human before any run.
  • An agent never passes --yes, --fence, --accept-git-head, --accept-behind, --take-over or --force unless the human's instruction for that run names it.
  • tack plan and tack status only read; an agent may run them freely.
  • When a run stops, report its reason and message to the human and wait.

Released under the Apache License 2.0.