Skip to content

T-KWJG-learning-p5-vault-import-and-hosted

State: planning/proposed · Impact: medium · Complexity: large

Run the same product on a server and let a desktop install download books from it. This phase adds the one generic platform primitive the plugin experiment found missing, import a vault from an archive, and deploys the web build behind platform-server as a personal hosted instance.

LocationRole today
solutions/determined/crates/determined-platform/src/bin/platform-server.rsServes the web build and /api; one mutation token, loopback by default; no identity
solutions/determined/crates/determined-platform/src/vault_workspace.rsThe suite roster; vaults are added by path
solutions/determined/crates/determined-platform/src/api/v1/vault_notes.rsReads assets; no asset write, no archive import
solutions/determined/apps/learning-cli/bundle produces the archive this phase imports

Platform-core gains import_vault_from_archive(bytes, name) as a generic op: unpack into the durable tier, register in the roster, return the vault id. The learning experience gains a catalog page that lists bundles from a configured catalog URL and imports one through that op. The hosted deploy is the books product web build served by platform-server with the platform token, the book vaults and one learner vault on its durable tier. Bundles are served as static files beside it.

  1. Add the import op in determined-platform beside the roster ops; size cap, path guard, zip-slip guard. Cover with a test.
  2. Catalog: a static catalog.json the CLI’s publish verb writes next to the bundles.
  3. The catalog page and download flow in the experience.
  4. A deploy recipe for the hosted instance: build, copy vaults, run platform-server with the token, document the escape hatches.
  5. Decide whether read_doc needs an embeds-inlined variant by measuring page loads over HTTP. Record the numbers on this task.
AreaNote
solutions/determined/crates/determined-platform/src/api/v1/The archive-import op
solutions/determined/experiences/learning/Catalog page, download flow
solutions/determined/apps/learning-cli/publish verb writing bundles and catalog.json
solutions/determined/docs/hosted.mdThe deploy recipe
  • AC-1: A desktop install with no books downloads one from a hosted catalog and opens it.
  • AC-2: Progress recorded on the hosted instance survives a restart.
  • AC-3: The import op rejects a zip with a path outside its root.
  • AC-4: The import op is the only new code under solutions/determined/.
  • Multi-user identity. Recorded as a platform gap in D-LIRI.
  • The embeds-inlined read. Measured here, built only if needed.
  • T-ZP78 so the hosted instance has something to persist.
  • D-LIRI.

T-ZP78


← Back to Tasks