openreader/docs-site/docs/configure/storage-and-blob-behavior.md
Richard R 9b9206f50d refactor(audiobooks): migrate audiobook pipeline to object storage
This commit restructures the audiobook generation and serving layer to rely exclusively on S3-compatible blob storage, removing the dependency on local filesystem paths.

- Bundle `ffmpeg` and `ffprobe` binaries via npm to ensure portability across environments.
- Update API routes to stream audio directly from blob storage instead of local disk.
- Remove legacy migration endpoints and filesystem-based indexing logic.
- Add startup scripts to facilitate the transition from local to remote storage.

BREAKING CHANGE: Audiobook functionality is now strictly dependent on S3 configuration. The previous filesystem-based storage method has been removed.
2026-02-11 02:44:34 -07:00

2 KiB

title
Object / Blob Storage

This page documents storage backends, blob upload routing, and Docker mount behavior.

Storage backends

  • Default: embedded SQLite metadata + embedded SeaweedFS (weed mini) blobs
  • External option: Postgres + external S3-compatible object storage

Storage variables are documented in Environment Variables under the storage sections.

Ports

  • 3003: OpenReader app and API routes
  • 8333: Embedded SeaweedFS S3 endpoint for direct browser blob access

Upload behavior

  • Primary path: browser uploads to presigned URL from /api/documents/blob/upload/presign
  • Fallback path: /api/documents/blob/upload/fallback if direct upload fails or endpoint is unreachable
  • Content serving path: /api/documents/blob
Mount Type Recommended Purpose Example
/app/docstore Docker named volume Yes (for persistence) Persists SeaweedFS blob data, SQLite metadata DB, migrations, and local runtime temp state -v openreader_docstore:/app/docstore
/app/docstore/library Bind mount Optional + :ro Read-only source for server library import (files are copied/imported into client storage) -v /path/to/your/library:/app/docstore/library:ro

To import from mounted library: Settings -> Documents -> Server Library Import.

:::note Every file in the mounted library is imported into client browser storage. Keep the library reasonably sized. :::

Private blob endpoint mode

If 8333 is not published externally:

  • Document uploads still work through upload fallback proxy
  • Reads/snippets continue through app API routes
  • Direct presigned browser upload/download to embedded endpoint is unavailable

Audiobook storage note

  • In current versions, audiobook assets live in object storage (audiobooks_v1 keyspace), not as durable files under /app/docstore.
  • Local filesystem usage for audiobook routes is temporary processing only.