push_files
Copies a local directory to a cluster over SSH with staged, retried transfers, overwriting same-name files without deleting others; choose tracked code files or all non-cache files.
Instructions
Copy a directory to the cluster (tar over SSH, retried; staged, so a failed push changes nothing; overwrites
files of the same name, never deletes others). mode='tracked': git-tracked and untracked-but-not-ignored files plus
a REVISION file, for code repositories; mode='all': everything except .git, venvs, caches and *.sif.
host: the machine local_dir is on ('' = the machine the server runs on; default: the server's client machine,
see the result's 'host'). local_dir must be inside the local root there (the home directory, outside hidden directories); remote_dir under $DATA, $SCRATCH or ~/
(e.g. '$DATA/'). Code only: big data is fetched in jobs.
Warns (does not refuse) when your pending or running jobs work in or around remote_dir: Slurm keeps only a copy
of the batch script, so pending jobs run the pushed code and running ones may read changed files mid-run.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | No | ||
| mode | No | tracked | |
| exclude | No | ||
| local_dir | Yes | ||
| remote_dir | Yes |