betterNAS/apps/control-plane
Harivansh Rathi b5f8ea9c52 Make control-plane the real mount authority
Split node enrollment from export sync and issue Finder-compatible DAV
credentials so the stack proves the real backend seam before any web UI
consumes it.
2026-04-01 17:46:50 +00:00
..
cmd/control-plane Make control-plane the real mount authority 2026-04-01 17:46:50 +00:00
Dockerfile init (#5) 2026-03-31 23:50:51 -04:00
go.mod init (#5) 2026-03-31 23:50:51 -04:00
package.json pnpm, verify, cleanup (#6) 2026-03-31 23:59:52 -04:00
README.md Make control-plane the real mount authority 2026-04-01 17:46:50 +00:00

betterNAS Control Plane

Go service that owns the product control plane.

It is intentionally small for now:

  • GET /health
  • GET /version
  • POST /api/v1/nodes/register
  • POST /api/v1/nodes/{nodeId}/heartbeat
  • PUT /api/v1/nodes/{nodeId}/exports
  • GET /api/v1/exports
  • POST /api/v1/mount-profiles/issue
  • POST /api/v1/cloud-profiles/issue

The request and response shapes must follow the contracts in packages/contracts.

/api/v1/* endpoints require bearer auth. New nodes register with BETTERNAS_CONTROL_PLANE_NODE_BOOTSTRAP_TOKEN, client flows use BETTERNAS_CONTROL_PLANE_CLIENT_TOKEN, and node registration returns an X-BetterNAS-Node-Token header for subsequent node-scoped register and heartbeat and export sync calls. Mount profiles now return standard WebDAV username and password credentials, and multi-export sync should send an explicit mountPath per export so mount profiles can stay stable across runtimes.