synor/docs/PLAN/PHASE9-SynorHosting/01-Milestone-01-HostingCore.md
Gulshan Yadav c829362729 feat(cli): add deploy command for Synor Hosting
Add `synor deploy` command group for deploying web applications:
- `synor deploy push` - upload project to Synor Hosting
- `synor deploy init` - create synor.json configuration
- `synor deploy list` - list all deployments
- `synor deploy delete` - remove a deployment

Features:
- synor.json configuration parsing with build/routes/headers
- Framework auto-detection (Next.js, Vite, Astro, Angular, SvelteKit)
- Build command execution with install support
- Multipart file upload to storage gateway
- Deployment name validation with reserved word protection
- Content type detection for 20+ MIME types

Also adds Phase 9 milestone documentation and marks Synor Hosting
as 100% complete in the roadmap.
2026-01-10 12:59:35 +05:30

1.3 KiB

Milestone 01: Hosting Core

On-chain name registry and domain verification for Synor Hosting

Status: Complete

Tasks

  • Create synor-hosting crate structure
  • Implement HostingName type with validation
  • Implement NameRegistry for on-chain name→CID mapping
  • Implement DomainVerifier with CNAME/TXT DNS verification
  • Implement HostingRouter with host-based request routing
  • Implement RouteConfig for SPA, redirects, and headers
  • Create error types and config parsing (synor.json)
  • Add comprehensive test coverage (23 tests)

Files

crates/synor-hosting/
├── Cargo.toml
├── src/
│   ├── lib.rs
│   ├── error.rs
│   ├── config.rs
│   ├── registry.rs
│   ├── domain.rs
│   └── router.rs

Key Types

  • HostingName: Validated deployment name (alphanumeric + hyphens, 3-63 chars)
  • NameEntry: Registry entry with CID, owner, expiry, custom domains
  • NameRegistry: In-memory registry for name→CID mapping
  • DomainVerifier: DNS verification for custom domains
  • HostingRouter: Routes requests by host header
  • RouteConfig: SPA mode, redirects, headers, error pages
  • SynorJson: Configuration file parser

Validation Commands

cargo test -p synor-hosting
cargo clippy -p synor-hosting -- -D warnings

Completed: January 2026