A real-time Reddit post collector and analyzer using Go, Kafka, and PostgreSQL.
- Go 1.21+
- Docker and Docker Compose
- Node.js & npm
- Reddit API credentials
-
Get Reddit API credentials from https://www.reddit.com/prefs/apps
- Create a new script app
- Note down client ID and secret
-
Configure the application:
cp config/config.example.yaml config/config.yaml
Update
config.yamlwith your Reddit credentials -
Install Go dependencies:
go mod download go mod tidy
-
Install frontend dependencies:
cd frontend npm install cd ..
-
Start infrastructure:
docker-compose up -d
-
Start the services (in separate terminals):
# Start producer go run cmd/producer/main.go # Start consumer go run cmd/consumer/main.go # Start API go run cmd/api/main.go # Start frontend (in frontend directory) cd frontend npm run dev
-
Visit http://localhost:5173 in your browser
docker-compose downTo completely reset (including volumes):
docker-compose down -v