feat: add Django web app, CloudKit sync, dashboard, and game_datetime_utc export
Adds the full Django application layer on top of sportstime_parser: - core: Sport, Team, Stadium, Game models with aliases and league structure - scraper: orchestration engine, adapter, job management, Celery tasks - cloudkit: CloudKit sync client, sync state tracking, sync jobs - dashboard: staff dashboard for monitoring scrapers, sync, review queue - notifications: email reports for scrape/sync results - Docker setup for deployment (Dockerfile, docker-compose, entrypoint) Game exports now use game_datetime_utc (ISO 8601 UTC) instead of venue-local date+time strings, matching the canonical format used by the iOS app. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
45
.env.example
Normal file
45
.env.example
Normal file
@@ -0,0 +1,45 @@
|
||||
# Django Settings
|
||||
DEBUG=False
|
||||
SECRET_KEY=generate-a-secure-key-with-python-c-from-django.core.management.utils-import-get_random_secret_key-print-get_random_secret_key
|
||||
ALLOWED_HOSTS=sportstime.yourdomain.com,localhost,127.0.0.1
|
||||
|
||||
# Admin User (created on first startup)
|
||||
ADMIN_USERNAME=admin
|
||||
ADMIN_PASSWORD=changeme
|
||||
ADMIN_EMAIL=admin@yourdomain.com
|
||||
|
||||
# Import initial data on first startup (set to true, then false after first run)
|
||||
IMPORT_INITIAL_DATA=true
|
||||
|
||||
# Database
|
||||
DB_PASSWORD=your-secure-database-password
|
||||
DATABASE_URL=postgresql://sportstime:${DB_PASSWORD}@db:5432/sportstime
|
||||
|
||||
# Redis
|
||||
REDIS_URL=redis://redis:6379/0
|
||||
|
||||
# CloudKit Configuration
|
||||
CLOUDKIT_CONTAINER=iCloud.com.sportstime.app
|
||||
CLOUDKIT_ENVIRONMENT=development
|
||||
CLOUDKIT_KEY_ID=your-cloudkit-key-id
|
||||
CLOUDKIT_PRIVATE_KEY_PATH=/app/secrets/cloudkit.pem
|
||||
|
||||
# Email (SMTP) - Example for Gmail
|
||||
EMAIL_HOST=smtp.gmail.com
|
||||
EMAIL_PORT=587
|
||||
EMAIL_USE_TLS=True
|
||||
EMAIL_HOST_USER=your-email@gmail.com
|
||||
EMAIL_HOST_PASSWORD=your-app-specific-password
|
||||
DEFAULT_FROM_EMAIL=SportsTime <noreply@yourdomain.com>
|
||||
ADMIN_EMAIL=admin@yourdomain.com
|
||||
|
||||
# Security (for production behind HTTPS proxy)
|
||||
SECURE_SSL_REDIRECT=False
|
||||
CSRF_TRUSTED_ORIGINS=https://sportstime.yourdomain.com
|
||||
SESSION_COOKIE_SECURE=True
|
||||
CSRF_COOKIE_SECURE=True
|
||||
|
||||
# Scraper Settings
|
||||
SCRAPER_REQUEST_DELAY=3.0
|
||||
SCRAPER_MAX_RETRIES=3
|
||||
SCRAPER_FUZZY_THRESHOLD=85
|
||||
Reference in New Issue
Block a user