The wizard supports two modes for registering apps in PortOS.
For apps already running on the system (any path, any user):
- Basic Info: Name, description, icon
- Location: Repo path (file picker or manual entry)
- Ports: UI port, API port (can auto-detect from running processes)
- Process Config:
- Start command(s)
- PM2 process name(s)
- Env file location
- Confirm & Register
- Detect running processes on specified ports
- Validate repo path exists
- Optional: import existing PM2 process into registry
- No scaffolding, no git operations
Scaffold a new project from template:
- Basic Info: Name, description
- Template: Select template (vite+express, node-server, static)
- Location: Parent directory for new repo
- Ports: Allocate from available range
- Git Setup:
- Initialize git
- Create GitHub repo (optional, via
ghCLI)
- Confirm & Create
- Copy template files
- Configure .env with ports
- Run
npm install - Initialize git + first commit
- Create GitHub repo (if selected)
- Generate PM2 ecosystem config
- Register in PortOS
- Start with PM2
| Route | Description |
|---|---|
| POST /api/apps | Register existing app |
| POST /api/scaffold | Create new app from template |
| GET /api/scaffold/templates | List available templates |
| POST /api/detect/ports | Detect process on port |
| POST /api/detect/repo | Validate repo path, detect type |