Persistent Workspaces on packet.ai mount a PVC at /workspace so your files, pip packages, and environment survive pod restarts — while you only pay for GPU time when the GPU is attached.
Key takeaways
/workspace and persists across all pod restarts — your files, packages, and models stay/workspace/home/ and writes a marker file so subsequent boots skip the copy/workspace/bin/ is automatically added to PATH — install binaries there for instant access across restarts/workspace/pip-packages/ persist when you set PYTHONPATH accordinglyGPU pods are ephemeral. Every restart, the container starts fresh from the base image. Persistent Workspaces solve this by mounting a PVC that outlives the GPU attachment, so your working environment accumulates over time rather than resetting to zero on every restart.
When you launch a GPU on packet.ai with persistent storage, we mount a PVC at /workspace. An init script runs on every pod start:
#!/bin/bash
if [ ! -d "/workspace" ]; then exit 0; fi
mkdir -p /workspace/home
# First boot: copy home directory to workspace
if [ ! -f "/workspace/home/.packet-init" ]; then
cp -r $HOME/. /workspace/home/ 2>/dev/null || true
touch /workspace/home/.packet-init
fi
# Add workspace bin to PATH
echo 'export PATH="/workspace/bin:$PATH"' >> /workspace/home/.bashrc
The marker file /workspace/home/.packet-init is the key: on first boot it doesn’t exist, so the home directory is copied. On all subsequent boots it exists, so the copy is skipped and your accumulated changes are preserved.
Persist pip packages:
# Install to workspace
pip install --target=/workspace/pip-packages torch transformers vllm
# Add to .bashrc in workspace (survives restarts)
echo 'export PYTHONPATH="/workspace/pip-packages:$PYTHONPATH"' \
>> /workspace/home/.bashrc
Auto-run setup on boot:
# Store requirements in workspace
pip freeze > /workspace/requirements.txt
# Startup script reads it
if [ -f /workspace/requirements.txt ]; then
pip install -r /workspace/requirements.txt
fi
Persist conda environments:
conda create --prefix /workspace/envs/myenv python=3.11
conda activate /workspace/envs/myenv
The economic case for Persistent Workspaces is straightforward: when your job is done for the day, detach the GPU. You stop paying the GPU hourly rate. Your workspace persists on the PVC (which has its own lower storage rate). Reattach the next morning and you’re exactly where you left off — files, packages, conda environments, model weights all intact.
At H100 rates from $0.65/hr, an 8-hour workday costs $5.20. Without persistent workspaces, spending 30 minutes on setup each morning costs $0.33 in GPU time — plus the productivity loss. Across a team of 5 engineers, that’s $1.65/day or ~$430/year burned on reinstalling packages.
Last reviewed: 10 June 2026. Browse GPU clusters on packet.ai →
Same models. Same API. Fraction of the cost. Start free — no credit card required.
Start Building →