Initial Mist scaffold
Successor to the Josh Steam prototypes. Single-VM Docker Compose stack with
the load-bearing core/ logic ported from JoshSteam CDN with bug fixes.
Contents:
- backend/ FastAPI + Celery (same image, two entrypoints)
core/ hdiff, librsync, chain_replay, manifest, compression,
discord, steam, unrealpak, paths
api/ auth, catalog, admin, builds (skeletons) + downloads (real)
worker/ Celery factory replacing the missing prototype Tasks/__init__.py
db/ SQLAlchemy models + Alembic initial migration
- admin-web/ SvelteKit + Tailwind skeleton
- client/ Tauri 2 + Svelte skeleton (Mist placeholder UI)
- mistpipe/ click-based admin CLI with subcommand stubs
- docs/ ARCHITECTURE, DECISIONS (9 ADRs), RUNBOOK
- docker-compose.yml + dev overlay + .github/workflows
Bugs fixed during port:
- Routes/download.py:2 stray backslash on import line
- Utils/celery.py inspect.reserved() missing parens + double active() typo
- Hardcoded OneDrive/Desktop paths replaced with pydantic-settings config
- Discord webhook URL + RabbitMQ password moved to env vars
- Missing Tasks/__init__.py reconstructed as worker/__init__.py
Out of scope for this commit: route bodies, UI screens, mistpipe subcommand
bodies, real image builds.
This commit is contained in:
@@ -0,0 +1,97 @@
|
||||
# Mist — production-ish Docker Compose stack.
|
||||
# Brings up: postgres, redis, rabbitmq, api, worker, admin-web.
|
||||
# All env config comes from .env (copy from .env.example).
|
||||
|
||||
services:
|
||||
postgres:
|
||||
image: postgres:16-alpine
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
POSTGRES_USER: ${POSTGRES_USER}
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_DB: ${POSTGRES_DB}
|
||||
volumes:
|
||||
- postgres-vol:/var/lib/postgresql/data
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
redis:
|
||||
image: redis:7-alpine
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- redis-vol:/data
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
rabbitmq:
|
||||
image: rabbitmq:3.13-management-alpine
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
RABBITMQ_DEFAULT_USER: ${RABBITMQ_DEFAULT_USER}
|
||||
RABBITMQ_DEFAULT_PASS: ${RABBITMQ_DEFAULT_PASS}
|
||||
volumes:
|
||||
- rabbitmq-vol:/var/lib/rabbitmq
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
api:
|
||||
image: ghcr.io/REPLACE_ME/mist-backend:latest
|
||||
build:
|
||||
context: ./backend
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- postgres
|
||||
- redis
|
||||
- rabbitmq
|
||||
env_file:
|
||||
- .env
|
||||
volumes:
|
||||
- cache-vol:/mist/cache
|
||||
- tmp-vol:/mist/tmp
|
||||
# TODO: bind-mount NAS NFS export here. Configure host-side NFS mount,
|
||||
# then uncomment the line below and point it at the host mount point.
|
||||
# - /mnt/nas:/mnt/nas:rw
|
||||
ports:
|
||||
- "8000:8000"
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
worker:
|
||||
image: ghcr.io/REPLACE_ME/mist-backend:latest
|
||||
build:
|
||||
context: ./backend
|
||||
restart: unless-stopped
|
||||
command: ["celery", "-A", "mist.worker", "worker", "--loglevel=INFO"]
|
||||
depends_on:
|
||||
- postgres
|
||||
- redis
|
||||
- rabbitmq
|
||||
env_file:
|
||||
- .env
|
||||
volumes:
|
||||
- cache-vol:/mist/cache
|
||||
- tmp-vol:/mist/tmp
|
||||
# - /mnt/nas:/mnt/nas:rw
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
admin-web:
|
||||
image: ghcr.io/REPLACE_ME/mist-admin-web:latest
|
||||
build:
|
||||
context: ./admin-web
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "5173:80"
|
||||
networks:
|
||||
- mist-net
|
||||
|
||||
volumes:
|
||||
postgres-vol:
|
||||
redis-vol:
|
||||
rabbitmq-vol:
|
||||
cache-vol:
|
||||
tmp-vol:
|
||||
|
||||
networks:
|
||||
mist-net:
|
||||
driver: bridge
|
||||
Reference in New Issue
Block a user