Backups and restore
Backup and restore are D1 jobs on the instance. Restore prefers on-disk inventory from backup.List.
Jobs, not a gallery
Backup and restore are job kinds on the same instance_id. The tab lists those D1 rows. Create and restore queue without changing desired power; foxd stops the guest for the job, then starts again when desired power is running. foxd writes a local tarball for now; object storage comes later.
When the node session is ready, on-disk archives list via the NodeSession backup.List RPC (job id, size, modified time — bytes stay on the node). Delete drops one archive by job id via backup.Delete on the same session (foxd gates to assigned instances). If the list fails, that section uses UnavailablePanel instead of inventing a gallery. Restore latest stays off until that list shows a tarball (or, if list fails, until a backup job succeeds). It always unpacks the newest listed archive — not a selected older job id — after it clears the instance data dir before unpack, so files added after that backup do not survive. While a backup or restore job is open, the controls wait and the tab refreshes job status and on-disk archives until the job settles — it does not block on the node. No node, or a stale/dead session, hides create, restore, delete, and archive inventory behind UnavailablePanel; job history from D1 still shows.
From the panel
Open Backups when the node is ready to create, restore, or delete an on-disk archive. Keep the instance id. Do not destroy the instance if you still need the volume.
- Open the instance from Services.
- Open Backups when the node session is ready.
- Create backup and wait for the job to succeed and the archive to appear.
- Use Restore latest when On-disk archives lists a tarball, Delete to drop one archive, or write to support with the instance id.
Where a backup is stored
The tarball stays on the node that ran the guest. It is not an off-site copy. Restore uses the newest listed archive, not a selected older job id, and it clears the instance data dir first. backup.List and backup.Delete talk to that node. If the session is down, UnavailablePanel replaces the archive list. Create stays off until that list shows a tarball when the list itself succeeded.