Files
storyforge/deploy/storyforge-fnos-live-recorder.compose.yaml
kris 4546c95e8c
Some checks failed
StoryForge CI / Baseline checks (push) Has been cancelled
StoryForge CI / Backend tests (push) Has been cancelled
StoryForge CI / Web tests (push) Has been cancelled
fix: restore fnos live recorder deployment
2026-04-06 08:55:56 +08:00

65 lines
2.5 KiB
YAML

services:
# StoryForge server-side live recorder for multi-platform sources.
#
# Recommended upstream source repo:
# /Users/kris/code/DouyinLiveRecorder-main
#
# Rationale:
# - Supports 40+ live platforms.
# - Linux/Docker friendly.
# - Exposes HTTP APIs that StoryForge can call directly:
# GET /api/healthz
# GET /api/status-lite
# GET /api/status
# GET /api/recordings
# POST /api/url-config/import
# POST /api/url-config/set-enabled
# POST /api/recorder/start
# POST /api/recorder/stop
# GET /api/downloads
# GET /downloads/<path>
#
# Suggested fnOS state root:
# /vol1/docker/hyzq-stack/shared/storyforge-live-recorder
#
# Suggested fnOS external port:
# 19106
#
# Example StoryForge call flow:
# 1. POST /api/url-config/import
# {"raw":"原画,https://live.kuaishou.com/u/anchor123"}
# 2. POST /api/recorder/start
# 3. Poll GET /api/status-lite or /api/recordings
# 4. Read output via GET /api/downloads or /downloads/<path>
storyforge-live-recorder:
image: ${STORYFORGE_LIVE_RECORDER_IMAGE:-storyforge-live-recorder:fnos}
build:
context: ../../storyforge/live-recorder-source
dockerfile: Dockerfile.storyforge
args:
BASE_IMAGE: ${STORYFORGE_LIVE_RECORDER_BASE_IMAGE:-docker.m.daocloud.io/library/python:3.11-slim}
container_name: storyforge-live-recorder
restart: unless-stopped
tty: true
stdin_open: true
command: ["python", "webui.py", "--host", "0.0.0.0", "--port", "8899"]
ports:
- "${STORYFORGE_LIVE_RECORDER_PORT:-19106}:8899"
environment:
TERM: xterm-256color
TZ: ${TZ:-Asia/Shanghai}
WEBUI_HOST: 0.0.0.0
WEBUI_PORT: 8899
RECORDER_PYTHON: python
volumes:
- "${STORYFORGE_LIVE_RECORDER_STATE_ROOT:-/vol1/docker/hyzq-stack/shared/storyforge-live-recorder}/config:/app/config"
- "${STORYFORGE_LIVE_RECORDER_STATE_ROOT:-/vol1/docker/hyzq-stack/shared/storyforge-live-recorder}/logs:/app/logs"
- "${STORYFORGE_LIVE_RECORDER_STATE_ROOT:-/vol1/docker/hyzq-stack/shared/storyforge-live-recorder}/backup_config:/app/backup_config"
- "${STORYFORGE_LIVE_RECORDER_STATE_ROOT:-/vol1/docker/hyzq-stack/shared/storyforge-live-recorder}/downloads:/app/downloads"
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8899/api/healthz', timeout=5).read()"]
interval: 30s
timeout: 10s
retries: 3
start_period: 20s