feat: first-run web installer with admin account creation
- Backend: app_settings table + users.is_admin flag (schema + migrate)
- POST /api/setup creates admin user, first workspace and marks installed
(transactional, single-use, rate-limited); GET /api/setup/status
- Guard middleware: API answers 503 { setupRequired: true } until installed
- Frontend: /setup wizard (welcome, admin account, workspace), router guard
redirects to installer when uninstalled, API interceptor handles 503
- Docs: installer covered in README, SETUP, HOSTING and ROADMAP
This commit is contained in:
@@ -122,6 +122,9 @@ curl http://localhost:3000/api/health
|
||||
- Frontend: `http://<host>:8080`
|
||||
- Backend API: `http://<host>:3000/api/health`
|
||||
- Data persists in the `pgdata` volume.
|
||||
- On first start, open the frontend and complete the **web installer**
|
||||
(admin account + first workspace). Until then the API answers
|
||||
`503 { setupRequired: true }` for all app routes.
|
||||
|
||||
### Reverse proxy (TLS) in front of Compose
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
## Phase 1 — Web app MVP (this repo, v0.1) ✅
|
||||
|
||||
- [x] Auth (register/login/JWT), workspaces, invites, roles
|
||||
- [x] First-run web installer (admin account + first workspace, API locked until done)
|
||||
- [x] Nested pages, TipTap rich text, comments, search
|
||||
- [x] Socket.IO realtime (live updates, presence, typing)
|
||||
- [x] Light/dark mode
|
||||
|
||||
+4
-2
@@ -57,8 +57,10 @@ npm install
|
||||
npm run dev # http://localhost:5173
|
||||
```
|
||||
|
||||
Open the frontend, **Register** the first user, create a workspace, invite teammates
|
||||
by email (they must register with the same email first).
|
||||
Open the frontend, where the **first-run web installer** (`/setup`) creates the admin
|
||||
account (`is_admin=true`) and the first workspace, then logs you in automatically.
|
||||
Further teammates **Register** themselves and are invited by email
|
||||
(they must register with the same email first).
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
|
||||
Reference in New Issue
Block a user