-
Notifications
You must be signed in to change notification settings - Fork 0
Configuration
Retro-Jack edited this page Aug 6, 2026
·
2 revisions
All settings live in the Configuration block at the top of epubify.sh.
| Variable | Description |
|---|---|
INPUT_DIR |
Folder holding the PDFs to convert. Must exist — the script stops if it doesn't. |
STAGING_DIR |
Staging folder for PDFs awaiting conversion. Created if missing. |
OUTPUT_DIR |
Root for converted documents. Created if missing. |
MODEL_CACHE |
Where pdf2epub's downloaded models live between runs. Created if missing. |
| Variable | Description |
|---|---|
IMAGE |
Image to run. Default ghcr.io/overcuriousity/pdf2epub:latest. |
BUILD_CONTEXT |
Optional path to a pdf2epub checkout. Used to build the image locally if the pull fails; leave empty to skip that fallback. |
INPUT_READ_ONLY |
Mount the staging tree read-only. Default true. Set false if a conversion fails with a read-only filesystem error. |
EXTRA_ARGS |
Extra arguments appended to every pdf2epub invocation, e.g. EXTRA_ARGS=(--start-page 10 --max-pages 50). |
CONTAINER_MEM_MAX |
Hard memory ceiling per conversion. Default 8G; empty disables. |
CONTAINER_TIMEOUT |
Wall-clock limit per conversion. Default 2h; empty disables. |
The two ceilings exist so a malformed PDF that makes the model pipeline balloon gets killed locally instead of taking the desktop session with it.
| Variable | Description |
|---|---|
PROCESS_DELAY |
Seconds to pause between conversions. Default 2. |
EXCLUDED_BASENAMES |
Filenames (without extension) to skip entirely, e.g. sample, preview. |
TIDY_NAMES |
Normalise separators and apply title case to output names. Default true. See Name Tidying. |
ERROR_LOG defaults to error_log.txt inside OUTPUT_DIR. It's created lazily — a clean run leaves no file at all.