docs: add wrap-up to Dockerfile, .env.example, README
Some checks failed
CI / Check / Test (push) Failing after 42s
Some checks failed
CI / Check / Test (push) Failing after 42s
This commit is contained in:
@@ -62,4 +62,10 @@ EVENT_BUS_BACKEND=db
|
|||||||
# IMAGE_CONVERSION_ENABLED=false
|
# IMAGE_CONVERSION_ENABLED=false
|
||||||
# IMAGE_CONVERSION_FORMAT=avif # avif | webp
|
# IMAGE_CONVERSION_FORMAT=avif # avif | webp
|
||||||
|
|
||||||
|
# Annual Wrap-Up (video generation — optional, requires ffmpeg)
|
||||||
|
# WRAPUP_FONT_PATH=/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf
|
||||||
|
# WRAPUP_LOGO_PATH=./static/logo.webp
|
||||||
|
# FFMPEG_PATH=ffmpeg
|
||||||
|
# WRAPUP_MAX_CONCURRENT=2
|
||||||
|
|
||||||
RUST_LOG=presentation=debug,tower_http=debug,worker=info,application=info
|
RUST_LOG=presentation=debug,tower_http=debug,worker=info,application=info
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ COPY crates/tui/Cargo.toml crates/tui/Cargo.toml
|
|||||||
COPY crates/adapters/image-converter/Cargo.toml crates/adapters/image-converter/Cargo.toml
|
COPY crates/adapters/image-converter/Cargo.toml crates/adapters/image-converter/Cargo.toml
|
||||||
COPY crates/adapters/sqlite-search/Cargo.toml crates/adapters/sqlite-search/Cargo.toml
|
COPY crates/adapters/sqlite-search/Cargo.toml crates/adapters/sqlite-search/Cargo.toml
|
||||||
COPY crates/adapters/postgres-search/Cargo.toml crates/adapters/postgres-search/Cargo.toml
|
COPY crates/adapters/postgres-search/Cargo.toml crates/adapters/postgres-search/Cargo.toml
|
||||||
|
COPY crates/adapters/wrapup-renderer/Cargo.toml crates/adapters/wrapup-renderer/Cargo.toml
|
||||||
COPY crates/worker/Cargo.toml crates/worker/Cargo.toml
|
COPY crates/worker/Cargo.toml crates/worker/Cargo.toml
|
||||||
|
|
||||||
# Stub every crate so cargo can resolve and fetch deps
|
# Stub every crate so cargo can resolve and fetch deps
|
||||||
@@ -71,6 +72,8 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
ca-certificates \
|
ca-certificates \
|
||||||
wget \
|
wget \
|
||||||
libwebp7 \
|
libwebp7 \
|
||||||
|
ffmpeg \
|
||||||
|
fonts-dejavu-core \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|||||||
30
README.md
30
README.md
@@ -17,6 +17,7 @@ A self-hosted, server-side rendered movie logging system with a full REST API. B
|
|||||||
- Watchlist — add movies to watch later, per-user; federated watchlist entries visible for remote actors
|
- Watchlist — add movies to watch later, per-user; federated watchlist entries visible for remote actors
|
||||||
- User profiles — display name, bio, avatar, banner, custom profile fields; editable via HTML settings page or REST API
|
- User profiles — display name, bio, avatar, banner, custom profile fields; editable via HTML settings page or REST API
|
||||||
- Jellyfin/Plex auto-import — media server sends a webhook on playback stop, movies land in a watch queue; review and confirm with a rating to create diary entries; per-user webhook tokens with SHA-256 auth; setup UI at `/settings/integrations`
|
- Jellyfin/Plex auto-import — media server sends a webhook on playback stop, movies land in a watch queue; review and confirm with a rating to create diary entries; per-user webhook tokens with SHA-256 auth; setup UI at `/settings/integrations`
|
||||||
|
- Annual Wrap-Up — Spotify Wrapped for movies: per-user and instance-wide year-in-review with stats (top directors, actors, genres, rating distribution, watch time, rewatches, budget analysis), shareable HTML page at `/wrapups/{user_id}/{year}`, downloadable MP4 video with branded slides; admin-triggered or auto-generated in January
|
||||||
- CSV and JSON diary export
|
- CSV and JSON diary export
|
||||||
- File importer: upload CSV, TSV, JSON, or XLSX from any source (Letterboxd, IMDb, etc.), map columns to domain fields via a step-by-step wizard or REST API, save mapping profiles for repeat imports
|
- File importer: upload CSV, TSV, JSON, or XLSX from any source (Letterboxd, IMDb, etc.), map columns to domain fields via a step-by-step wizard or REST API, save mapping profiles for repeat imports
|
||||||
- REST API v1 (`/api/v1/`) with full feature parity with the HTML interface
|
- REST API v1 (`/api/v1/`) with full feature parity with the HTML interface
|
||||||
@@ -56,6 +57,7 @@ adapters/
|
|||||||
postgres-event-queue — durable polling event queue backed by PostgreSQL
|
postgres-event-queue — durable polling event queue backed by PostgreSQL
|
||||||
nats — NATS Core / JetStream event publisher and consumer
|
nats — NATS Core / JetStream event publisher and consumer
|
||||||
event-publisher — in-memory event channel (used in tests)
|
event-publisher — in-memory event channel (used in tests)
|
||||||
|
wrapup-renderer — annual wrap-up video generator (slide compositing via image crate, charts via plotters, stitching via ffmpeg)
|
||||||
activitypub — ActivityPub federation adapter (follow, inbox/outbox, actor); delegates to k-ap for protocol internals
|
activitypub — ActivityPub federation adapter (follow, inbox/outbox, actor); delegates to k-ap for protocol internals
|
||||||
sqlite-search — SQLite FTS5 implementation of SearchPort + SearchCommand
|
sqlite-search — SQLite FTS5 implementation of SearchPort + SearchCommand
|
||||||
postgres-search — PostgreSQL tsvector + GIN implementation of SearchPort + SearchCommand
|
postgres-search — PostgreSQL tsvector + GIN implementation of SearchPort + SearchCommand
|
||||||
@@ -109,6 +111,12 @@ IMAGE_STORAGE_PATH=./images
|
|||||||
# IMAGE_CONVERSION_ENABLED=false
|
# IMAGE_CONVERSION_ENABLED=false
|
||||||
# IMAGE_CONVERSION_FORMAT=avif # avif or webp
|
# IMAGE_CONVERSION_FORMAT=avif # avif or webp
|
||||||
|
|
||||||
|
# Annual Wrap-Up video (optional — requires ffmpeg)
|
||||||
|
# WRAPUP_FONT_PATH=/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf
|
||||||
|
# WRAPUP_LOGO_PATH=./static/logo.webp # watermark on video slides
|
||||||
|
# FFMPEG_PATH=ffmpeg
|
||||||
|
# WRAPUP_MAX_CONCURRENT=2 # max parallel video renders
|
||||||
|
|
||||||
# Optional
|
# Optional
|
||||||
HOST=0.0.0.0
|
HOST=0.0.0.0
|
||||||
PORT=3000
|
PORT=3000
|
||||||
@@ -177,7 +185,7 @@ The `application` crate has unit tests for core use cases backed by in-memory fa
|
|||||||
|
|
||||||
## Docker
|
## Docker
|
||||||
|
|
||||||
The image contains both `presentation` (HTTP server) and `worker` (event processor). Run them as separate containers sharing the same data volume:
|
The image contains both `presentation` (HTTP server) and `worker` (event processor), plus `ffmpeg` and DejaVu fonts for wrap-up video generation. Run them as separate containers sharing the same data volume:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Build (SQLite + federation + NATS support)
|
# Build (SQLite + federation + NATS support)
|
||||||
@@ -232,6 +240,26 @@ Auto-log movies you finish watching. Go to `/settings/integrations` to generate
|
|||||||
|
|
||||||
Movies you finish watching appear in your watch queue at `/watch-queue` — rate and confirm to add to your diary.
|
Movies you finish watching appear in your watch queue at `/watch-queue` — rate and confirm to add to your diary.
|
||||||
|
|
||||||
|
## Annual Wrap-Up
|
||||||
|
|
||||||
|
Generate a year-in-review summary for any user — top directors, actors, genres, rating distribution, total watch time, rewatch stats, and more. Available as a shareable HTML page and downloadable MP4 video.
|
||||||
|
|
||||||
|
**Generate via API** (admin only):
|
||||||
|
```bash
|
||||||
|
curl -X POST http://localhost:3000/api/v1/wrapups/generate \
|
||||||
|
-H "Authorization: Bearer <admin-token>" \
|
||||||
|
-H "Content-Type: application/json" \
|
||||||
|
-d '{"user_id": "<uuid>", "start_date": "2025-01-01", "end_date": "2026-01-01"}'
|
||||||
|
```
|
||||||
|
|
||||||
|
Omit `user_id` for a global instance wrap-up. The worker computes stats in the background — poll `GET /api/v1/wrapups/{id}` for status.
|
||||||
|
|
||||||
|
**View:** `http://localhost:3000/wrapups/{user_id}/2025` (public, no login required)
|
||||||
|
|
||||||
|
**Auto-generate:** The worker runs a daily job in January that generates wrap-ups for all users with reviews in the previous year.
|
||||||
|
|
||||||
|
**Video:** Requires `ffmpeg` installed. Set `WRAPUP_FONT_PATH` and `WRAPUP_LOGO_PATH` for branded slides. Download via `GET /api/v1/wrapups/{id}/video`.
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
MIT License. See [LICENSE](LICENSE).
|
MIT License. See [LICENSE](LICENSE).
|
||||||
|
|||||||
Reference in New Issue
Block a user