S3+S4: user param auth, static file serving, Docker deploy config
- replace hardcoded benji with ?user= query param - add GET /api/users and GET /api/me?user= endpoints - serve frontend static files via tower-http ServeDir - add multi-stage Dockerfile (Rust + Vite → single image) - add docker-compose.yml + Caddyfile for apes.unslope.com - frontend: getCurrentUsername() from URL param → localStorage - sidebar shows current user Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
33
infra/colony/docker-compose.yml
Normal file
33
infra/colony/docker-compose.yml
Normal file
@@ -0,0 +1,33 @@
|
||||
services:
|
||||
colony:
|
||||
build:
|
||||
context: ../..
|
||||
dockerfile: infra/colony/Dockerfile
|
||||
container_name: colony
|
||||
environment:
|
||||
- PORT=3001
|
||||
- DATABASE_URL=sqlite:/data/colony.db?mode=rwc
|
||||
volumes:
|
||||
- colony_data:/data
|
||||
ports:
|
||||
- "3001:3001"
|
||||
restart: always
|
||||
|
||||
caddy:
|
||||
image: caddy:latest
|
||||
container_name: colony-caddy
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
volumes:
|
||||
- ./Caddyfile:/etc/caddy/Caddyfile
|
||||
- caddy_data:/data
|
||||
- caddy_config:/config
|
||||
restart: always
|
||||
depends_on:
|
||||
- colony
|
||||
|
||||
volumes:
|
||||
colony_data:
|
||||
caddy_data:
|
||||
caddy_config:
|
||||
Reference in New Issue
Block a user