Skip to content

kevinshowkat/superjumbo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Superjumbo logo

Jumbo (web + server)

Unified repository containing the Jumbo React front end and Django REST API. Use this codebase to explore the project locally or as a starting point for your own deployment.

What it is

Super Jumbo / Wager Town is a sports prediction game for groups. It supports picks, leaderboards, and paid entries (Stripe) with optional web push notifications.

Features

  • create prediction games and props
  • invite friends, track picks, and score results
  • payments via Stripe (optional)
  • web push notifications (optional)

Stack

Layer Tech
Web React + TypeScript + Webpack
API Django + Django REST Framework
Jobs Celery + Redis

Repo layout

  • apps/server – Django API, Celery worker definitions, Procfile.
  • apps/web – React/TypeScript client and shared core package.
  • LICENSE – MIT license for open-source use.

Prerequisites

  • Python 3.8+ (Django 2.2 is tested up to 3.8)
  • Node 16 (webpack 4/React 16 toolchain)
  • Redis (optional, only for Celery tasks)

Quickstart

Open two terminals from the repo root.

1) API server

cd apps/server
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env   # edit values as needed
python manage.py migrate
python manage.py runserver

The API listens on http://127.0.0.1:8000 with routes under /api.

2) Web client

cd apps/web
npm install
npm start

The dev server runs at http://127.0.0.1:8080 and calls the API at http://127.0.0.1:8000/api by default.

Configuration

  • Server: driven by environment variables (apps/server/.env.example lists all options). Provide your own DJANGO_SECRET_KEY, Stripe keys, VAPID keys, and Redis URL as needed.
  • Web: runtime config is read from window.__JUMBO_CONFIG__ defined in apps/web/jumbo/index.html or from build-time env vars (API_ROOT, STRIPE_PUBLIC_KEY, VAPID_PUBLIC_KEY).

Testing

  • Server: cd apps/server && python manage.py test
  • Web: cd apps/web && npm test (Jest) or npm run test:e2e (Cypress)

Deployment

This repo is framework-agnostic. For Heroku-like deploys, use the Procfile in apps/server and supply env vars. The web app builds to apps/web/dist via npm run build; serve the static bundle from any CDN or static host.

Security note

All previously hard-coded secrets and service-account files were removed. Generate your own keys before deploying anything beyond local development.

About

Free-to-play sports prediction game

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published