38 lines
1.1 KiB
Markdown
38 lines
1.1 KiB
Markdown
# Super Sunday Padel — Full PROD bundle
|
|
|
|
Stack: **Postgres 16 + Node/Express API + Nginx static frontend**
|
|
Features: Players, Teams, Tournaments, Enrollments, Matches, Results, **Americano generator**, JWT Auth, basic admin SPA.
|
|
|
|
## Quick start
|
|
|
|
```bash
|
|
cp .env.example .env
|
|
docker compose up -d --build
|
|
# Open http://localhost:8080
|
|
# Admin at http://localhost:8080/admin (login with ADMIN_EMAIL / ADMIN_PASSWORD from .env)
|
|
```
|
|
|
|
## Push to Gitea (example)
|
|
```bash
|
|
git init
|
|
git add .
|
|
git commit -m "Super Sunday full prod v1"
|
|
git remote add origin <URL_DE_TON_GITEA>
|
|
git push -u origin main
|
|
```
|
|
|
|
## API (highlights)
|
|
- `POST /api/auth/login` -> { token }
|
|
- `GET /api/health`
|
|
- Players: `GET/POST/PUT/DELETE /api/players`
|
|
- Teams: `GET/POST/PUT/DELETE /api/teams`
|
|
- Tournaments: `GET/POST/PUT/DELETE /api/tournaments`
|
|
- Enrollments: `GET/POST/DELETE /api/enrollments`
|
|
- Matches: `GET/POST/PUT /api/matches`, `POST /api/matches/generate` (Americano)
|
|
- Scores: `POST /api/matches/:id/score`
|
|
|
|
Protected routes require `Authorization: Bearer <token>`.
|
|
|
|
## Notes
|
|
- Change `JWT_SECRET` and admin credentials before going live.
|
|
- SQL seed creates minimal schema + demo tournament. |