1.0 KiB
1.0 KiB
Shooting Event Phoenix Backend
This folder contains a Phoenix + SQLite implementation of the existing Go API contract used by the Vue frontend.
Run (dev)
cd phoenix
mix deps.get
mix ecto.create
mix ecto.migrate
PORT=8080 mix phx.server
Or from project root:
make phoenix-dev
Build
make phoenix-build
API compatibility
The Phoenix app exposes the same /api/* endpoints currently used by the Vue app, including:
- Public:
GET /api/healthGET /api/stateGET /api/events(SSE)
- Admin:
POST /api/admin/loginPOST /api/admin/logoutGET /api/admin/statePUT /api/admin/settings- Player CRUD + auto-group
- Score/proof update/delete + reset
- AI score advice endpoint
Environment
PORT(default:8080)DB_PATH(default:../data/shooting_phoenix.db)ADMIN_USER(default:datwyler)ADMIN_PASS(default:datwyler)GEMINI_API_KEY(default follows existing project fallback)GEMINI_MODEL(default:gemini-3.1-flash-lite-preview)