A real-time, lightweight application for crowdsourcing and ranking questions during a presentation, Q&A session, or meeting. Built using a Go backend for fast API handling and a React/Vite frontend for a modern, responsive user experience.
Live demo: https://question-app.duckdns.org
You must have Docker and Docker Compose installed on your system.
SQLite is the default storage backend. No database container is needed.
docker compose up --build
The following services will be available:
- Frontend: http://localhost:5173
- Backend API: http://localhost:8081
Session data is persisted in a named Docker volume (sqlite-dev-data). To wipe it, run docker compose down -v.
To use MongoDB instead, activate the mongo profile and set DB_DRIVER:
DB_DRIVER=mongodb docker compose --profile mongo up --build
The MongoDB instance is available at mongodb://devroot:devpassword@localhost:27017.
The backend supports two storage drivers, selected via the DB_DRIVER environment variable:
DB_DRIVER |
Description |
|---|---|
sqlite (default) |
Embedded SQLite database. No extra service required. Data stored at SQLITE_FILE (default: data.db). |
mongodb |
External MongoDB instance. Requires MONGO_URI to be set. |
Sessions expire after 24 hours. SQLite uses a background cleanup goroutine; MongoDB uses a TTL index.
| Variable | Default | Description |
|---|---|---|
DB_DRIVER |
sqlite |
Storage backend (sqlite or mongodb) |
SQLITE_FILE |
data.db |
Path to the SQLite database file |
MONGO_URI |
— | MongoDB connection string (required when DB_DRIVER=mongodb) |
PORT |
8081 |
Backend listen port |
CORS_ORIGINS |
http://localhost:5174 |
Allowed CORS origin |
ENV |
— | Set to production to enable secure cookies |
# Unit tests
go test ./...
# Integration tests (requires Docker for the MongoDB test)
go test -tags integration -v ./internal/storage/...
k6 load tests targeting the production environment are in k6/. See k6/README.md for usage.