d2e20ad82a989ae9cdd3639e23c6dae8b731863d
- Change build context from ./frontend|backend to root (.) - Update Dockerfiles to copy from correct paths - Use npm install instead of npm ci (workspaces share root lockfile) - Remove obsolete version attribute from docker-compose.yml Fixes npm ci errors when package-lock.json is at workspace root.
CoopCredits ($COOP) Media Rewards Ecosystem
A complete Solana-based rewards system integrated with Plex, Tautulli, and Overseer.
System Architecture
┌─────────────────────────────────────────────────────────────────────────────┐
│ coop.hobokenchicken.com │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ ┌─────────────────┐ │
│ │ Next.js │ │ Express │ │ PostgreSQL │ │ Solana Devnet │ │
│ │ Frontend │◄─┤ API │◄─┤ Database │◄─┤ $COOP SPL │ │
│ │ │ │ │ │ │ │ Token │ │
│ └──────────────┘ └──────────────┘ └──────────────┘ └─────────────────┘ │
│ ▲ ▲ │
│ │ │ │
│ Plex OAuth Tautulli Webhooks │
│ │ │ │
│ ▼ ▼ │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
│ │ Plex Server │ │ Tautulli │ │ Overseer │ │
│ │ (Content) │ │ (Analytics) │ │ (Requests) │ │
│ └──────────────┘ └──────────────┘ └──────────────┘ │
└─────────────────────────────────────────────────────────────────────────────┘
Quick Start
# 1. Clone and install dependencies
cd coop-credits
npm install
# 2. Set up environment
cp backend/.env.example backend/.env
# Edit backend/.env with your values
# 3. Start with Docker Compose
docker-compose up -d
# 4. Deploy Solana program
cd anchor-program
anchor deploy
# 5. Seed initial data
npm run db:seed
Project Structure
coop-credits/
├── anchor-program/ # Solana Anchor program for $COOP token
├── backend/ # Express API server
├── frontend/ # Next.js dashboard
├── shared/ # Shared types and utilities
├── docker/ # Docker configurations
├── deployment/ # Deployment scripts
└── docker-compose.yml # Full stack orchestration
User Flow
- Login → User visits coop.hobokenchicken.com, authenticates with Plex
- Wallet → Auto-created Solana wallet or connect existing
- Watch → Viewing on Plex → Tautulli triggers → $COOP minted
- Earn → Real-time balance updates on dashboard
- Spend → Request content on Overseer → $COOP deducted
- History → Full transaction history visible on dashboard
Admin Features
- System overview and analytics
- User management and balance adjustments
- Minting rate controls
- Spending controls and promotions
- Emergency pause and recovery
Environment Variables
See backend/.env.example and frontend/.env.local.example for full configuration.
Description
Watch-to-earn credits for your Plex server. Earn by watching, spend on content requests. Self-hosted economics for media nerds.
Languages
TypeScript
75.2%
Shell
19.8%
Rust
2.6%
CSS
1.3%
Dockerfile
0.9%
Other
0.2%