Expand description
Running a local command and reading its failure.
The interesting part is the reading. tailscale reports everything through
a non-zero exit code and a line of English on standard error, so this is
where that line becomes one of the error codes an agent can act on. Getting
it wrong is not cosmetic: needs_operator tells the caller to run one
command and try again, while unsupported_version tells it to stop asking.
Functions§
- command_
failure - The command ran and refused. Work out what kind of refusal it was.
- probe_
identity - Read who this node is from
tailscale status --json. - probe_
node - Who this node is and what it calls its peers, from one reading of status.
- probe_
version - Read the version out of
tailscale version. - run
- Run a command, and turn anything other than a clean exit into a tool error.
- run_
text - Run a command and hand back its standard output as text, failures aside.
- run_
tolerant - Run a command whose refusal may be an ordinary answer.
- version_
permits - Whether a tool’s stated minimum is met by the CLI we found.