Documentation
¶
Overview ¶
Package transfer covers SCP, SFTP, and rsync. SFTP is the workhorse for our upload/download paths because it's a real protocol over the SSH channel; SCP is offered for compatibility but SFTP is preferred whenever we control both ends.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Rsync ¶
func Rsync(s *store.Server, local, remote string, opts RsyncOptions) error
Rsync shells out to /usr/bin/rsync. Only key-based auth is supported here because we don't currently inject passwords into rsync's child SSH process. Password-auth servers will see rsync prompt and fail.
func SFTPInteractive ¶
SFTPInteractive runs an interactive SFTP session. We don't reimplement the full sftp(1) REPL — we shell out to the system sftp binary instead, since users expect its exact behaviour and tab completion. This is the only transfer path that shells out under normal operation.
(Rsync also shells out, by necessity — there's no Go-native rsync.)