Skip to main content
A workstation is a training job that exists for interactive work over SSH. baseten train workstation create starts one without a config.py: it configures an SSH session with InteractiveSessionTrigger.ON_STARTUP and runs sleep infinity to keep the container alive. A multi-node workstation runs the Slurm bootstrap instead.

Prerequisites

  • Training Jobs enabled for your organization. See Request access.
  • SSH set up on your machine. See Set up SSH.
  • uv on your PATH. The Baseten CLI runs Truss through uv to push jobs and create workstations.

Create and connect

A workstation holds its GPUs and is billed per minute while it runs. Disconnecting doesn’t stop it, so stop the workstation when you finish. Its SSH session expires, so save files you want to keep to the project cache, $BT_PROJECT_CACHE_DIR, before then. See Session expiry for how the timeout works.
To create a workstation and connect:
  1. Create the workstation. For example:
    Terminal
    The output lists the SSH host of each node, training-job-<job_id>-<node>.ssh.baseten.co. Copy <job_id> from it. The output also prints Truss commands for logs and stopping; use the Baseten CLI commands on this page instead. For all options, see baseten train workstation.
  2. When baseten train job describe --job-id <job_id> shows Status: running, connect:
    Terminal
    You’re connected when you see a shell prompt like root@baseten-training-job-<job_id>-multinode-0:~#.
  3. When you finish, stop the workstation and confirm when prompted:
For multi-node workstations, pass --node-count instead of --gpu-count: Baseten bootstraps a Slurm cluster across the nodes. See Slurm workstations.

Keep files in your home directory

Persistent home directories are in beta. Contact us to enable them for your organization. baseten train workstation create doesn’t have a --persistent-home flag. To keep files in your home directory after the workstation ends, run the Truss workstation command through the Baseten CLI with --persistent-home:
Terminal
Baseten places $HOME on the project cache at $BT_PROJECT_CACHE_DIR/homes/<job_id> and deletes it 7 days after the workstation ends. A new workstation gets a new home directory; to read an earlier one, open $BT_PROJECT_CACHE_DIR/homes/<earlier_job_id>. For a job defined in config.py, set persistent_home=True and enabled=True on its CacheConfig.

Next steps