Admin: import/re-add existing site from Dash Platform #15

Open
opened 2026-10-10 20:47:09 +00:00 by rhelwig · 0 comments
Owner

Summary

Admin should be able to import (re-add) a site that already exists on Dash Platform, working only from the published records: owner identity + contract + site key (or a decentsite: site reference / DNS discovery hint from #7). Today the only way to get a site into Admin is to create it locally.

Why

  • Recovery after local removal. Remove site (#13) only clears this Admin's local workspace. Platform records and IPFS content are untouched, so the published site stays live and readable. Admin has no way to pull it back in, though; the deleted-sites/ snapshot holds metadata only.
  • Multi-editor setup. A second editor (or a new laptop) should be able to set up their computer by pointing Admin at the published site and cloning the active release, instead of copying someone's data directory.
  • Disaster recovery. If a laptop dies, the published release is the source of truth.

Rough shape

  1. Add existing site on the Sites page. Input: a decentsite:?v=0&... reference, a hostname (use /.well-known/decentsite.json discovery while it resolves), or network + contract id + owner id + site key.
  2. Read-only resolve, reusing the open-site.mjs / site-ref code: site record → active release → page/post/asset/theme/aside versions → IPFS CIDs. Fetch every blob through the preferred sources and fallback gateways, and verify hashes (trustless raw/CAR path).
  3. Write it into the local workspace as a site linked to the existing contract/site record, with every item marked published at its current version. Store the active release as the base, so the next release can use only-changed reuse (#5) and doesn't re-version everything.
  4. Never write to Platform and never spend credits during import. Publishing afterwards still goes through Auth, and the identity that approves has to be authorized for the contract (see #3). Real multi-identity editing depends on the shared-contract v2 work.
  5. Show clearly what can't be recovered from Platform/IPFS: unpublished drafts, local-only settings, history before the active release.

Open questions

  • Re-import over an existing local copy: refuse, or offer a diff/merge?
  • Import older releases too, or only the active one?
  • Pin the imported blobs into the local Kubo automatically (fits the "run your own Kubo" guidance from #14)?

Context

Requested by Ron on 2026-10-10 after #13 (remove site) and #7 (no-DNS site references) landed.

## Summary Admin should be able to import (re-add) a site that already exists on Dash Platform, working only from the published records: owner identity + contract + site key (or a `decentsite:` site reference / DNS discovery hint from #7). Today the only way to get a site into Admin is to create it locally. ## Why - **Recovery after local removal.** *Remove site* (#13) only clears this Admin's local workspace. Platform records and IPFS content are untouched, so the published site stays live and readable. Admin has no way to pull it back in, though; the `deleted-sites/` snapshot holds metadata only. - **Multi-editor setup.** A second editor (or a new laptop) should be able to set up their computer by pointing Admin at the published site and cloning the active release, instead of copying someone's data directory. - **Disaster recovery.** If a laptop dies, the published release is the source of truth. ## Rough shape 1. *Add existing site* on the Sites page. Input: a `decentsite:?v=0&...` reference, a hostname (use `/.well-known/decentsite.json` discovery while it resolves), or network + contract id + owner id + site key. 2. Read-only resolve, reusing the `open-site.mjs` / site-ref code: site record → active release → page/post/asset/theme/aside versions → IPFS CIDs. Fetch every blob through the preferred sources and fallback gateways, and verify hashes (trustless raw/CAR path). 3. Write it into the local workspace as a site linked to the existing contract/site record, with every item marked published at its current version. Store the active release as the base, so the next release can use only-changed reuse (#5) and doesn't re-version everything. 4. Never write to Platform and never spend credits during import. Publishing afterwards still goes through Auth, and the identity that approves has to be authorized for the contract (see #3). Real multi-identity editing depends on the shared-contract v2 work. 5. Show clearly what can't be recovered from Platform/IPFS: unpublished drafts, local-only settings, history before the active release. ## Open questions - Re-import over an existing local copy: refuse, or offer a diff/merge? - Import older releases too, or only the active one? - Pin the imported blobs into the local Kubo automatically (fits the "run your own Kubo" guidance from #14)? ## Context Requested by Ron on 2026-10-10 after #13 (remove site) and #7 (no-DNS site references) landed.
Sign in to join this conversation.
No labels
feature request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
rhelwig/DecentSite#15
No description provided.