production fixes

This commit is contained in:
blaisadmin
2026-04-14 00:04:43 -04:00
parent 27bc463258
commit e0ab66d21a
8 changed files with 157 additions and 9 deletions
+20 -2
View File
@@ -27,10 +27,10 @@ FlockPal is a Dockerized TypeScript app for tracking flock health with a clean,
- Scheduled reminder delivery for birthdays, gotcha days, and care events
- Audit logging for workspace access changes and bird transfers
## Run locally
## Development
1. Copy `.env.example` to `.env` if you want custom settings.
2. Start the stack:
2. Start the development stack:
```bash
docker compose up --build
@@ -39,6 +39,24 @@ docker compose up --build
3. Open `http://localhost:3000`.
4. The API health check is available at `http://localhost:5000/api/health`.
The default `docker-compose.yml` is development-only. It mounts source files, installs dev dependencies, and runs the backend and frontend in watch mode.
## Production
1. Set production values in your environment or `.env`, especially:
- `POSTGRES_PASSWORD`
- `FRONTEND_URL`
- `BACKEND_URL`
- `VITE_API_BASE_URL`
2. Build and start the production stack:
```bash
docker compose -f docker-compose.prod.yml up --build -d
```
3. The production backend runs the compiled Node app from `dist/app.js`.
4. The production frontend is built with Vite and served by Nginx on port `3000`.
## Auth and workspace notes
- One user can belong to multiple workspaces.