seubert-claims/ondeck/SERVER.md

39 lines
941 B
Markdown
Raw Normal View History

# Horizon Dev Server
## How it runs
The app runs as a systemd service (`horizon.service`) and will automatically start on boot and restart on crash.
## Managing the server
```bash
systemctl start horizon # start
systemctl stop horizon # stop
systemctl restart horizon # restart
systemctl status horizon # check status
```
## Logs
```bash
tail -f /var/log/horizon.log
```
## Details
- **Port:** 3000 (proxied via Pangolin/Nginx to https://horizon.seubert.cloud)
- **Working directory:** `/opt/projects/OnDeck/ondeck`
- **Mode:** `npm run dev` (Next.js with Turbopack)
- **Service file:** `/etc/systemd/system/horizon.service`
## After code changes
Changes hot-reload automatically. If the server gets into a bad state:
```bash
systemctl restart horizon
```
## After schema changes
Run these before restarting:
```bash
cd /opt/projects/OnDeck/ondeck
npx prisma db push
npx prisma generate
systemctl restart horizon
```