Add Calibre-Web infrastructure
This commit is contained in:
11
.env.example
Normal file
11
.env.example
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
# Calibre-Web / books.mischlabs.de
|
||||||
|
TZ=Europe/Berlin
|
||||||
|
PUID=1000
|
||||||
|
PGID=1000
|
||||||
|
|
||||||
|
# External NAS port. Reverse proxy points books.mischlabs.de to this port.
|
||||||
|
APP_PORT=8083
|
||||||
|
|
||||||
|
# Persistent NAS paths. Keep these as bind mounts; do not move book data into Git.
|
||||||
|
BOOKS_PATH=/volume1/calibreweb/data/books
|
||||||
|
CONFIG_PATH=/volume1/calibreweb/data/config
|
||||||
5
.gitignore
vendored
Normal file
5
.gitignore
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
.env
|
||||||
|
*.log
|
||||||
|
tmp/
|
||||||
|
cache/
|
||||||
|
|
||||||
61
Brain.md
Normal file
61
Brain.md
Normal file
@@ -0,0 +1,61 @@
|
|||||||
|
# Calibre-Web Brain
|
||||||
|
|
||||||
|
Service: Calibre-Web / Books
|
||||||
|
|
||||||
|
Domain:
|
||||||
|
|
||||||
|
```text
|
||||||
|
https://books.mischlabs.de
|
||||||
|
```
|
||||||
|
|
||||||
|
Gitea target:
|
||||||
|
|
||||||
|
```text
|
||||||
|
https://git.mischlabs.de/MrDiderot/CalibreWeb.git
|
||||||
|
```
|
||||||
|
|
||||||
|
Current NAS state captured on 2026-05-21:
|
||||||
|
|
||||||
|
```text
|
||||||
|
Container: calibre-web
|
||||||
|
Image: lscr.io/linuxserver/calibre-web:latest
|
||||||
|
Ports: 0.0.0.0:8083->8083/tcp, :::8083->8083/tcp
|
||||||
|
Status: Up 4 days
|
||||||
|
```
|
||||||
|
|
||||||
|
Mounts:
|
||||||
|
|
||||||
|
```text
|
||||||
|
/volume1/calibreweb/data/books -> /books
|
||||||
|
/volume1/calibreweb/data/config -> /config
|
||||||
|
```
|
||||||
|
|
||||||
|
Environment:
|
||||||
|
|
||||||
|
```text
|
||||||
|
TZ=Europe/Berlin
|
||||||
|
PUID=1000
|
||||||
|
PGID=1000
|
||||||
|
```
|
||||||
|
|
||||||
|
Note: The live Compose file uses `PGID=${PGID:-10}`, but the inspected running container reported `PGID=1000`. This likely comes from the NAS `.env`. Preserve the NAS `.env` value when redeploying.
|
||||||
|
|
||||||
|
Compose path on NAS:
|
||||||
|
|
||||||
|
```text
|
||||||
|
/volume2/docker/calibreweb/docker-compose.yml
|
||||||
|
```
|
||||||
|
|
||||||
|
Decision:
|
||||||
|
|
||||||
|
- This is currently an infrastructure repository, not a custom app image repository.
|
||||||
|
- Use the upstream image `lscr.io/linuxserver/calibre-web:latest`.
|
||||||
|
- The universal Watchtower instance on the NAS can update this service directly.
|
||||||
|
- Only add a Dockerfile and Gitea Actions workflow if custom image changes become necessary later.
|
||||||
|
- The initial `docker-compose.yml` in this repo was copied from the live NAS compose file at `/volume2/docker/calibreweb/docker-compose.yml`.
|
||||||
|
|
||||||
|
Important:
|
||||||
|
|
||||||
|
- Do not move or delete `/volume1/calibreweb/data/books`.
|
||||||
|
- Do not move or delete `/volume1/calibreweb/data/config`.
|
||||||
|
- If Calibre-Web appears empty after deployment, check bind mounts before assuming data loss.
|
||||||
77
README.md
Normal file
77
README.md
Normal file
@@ -0,0 +1,77 @@
|
|||||||
|
# Calibre-Web / Books
|
||||||
|
|
||||||
|
Infrastructure repository for the Calibre-Web service at:
|
||||||
|
|
||||||
|
```text
|
||||||
|
https://books.mischlabs.de
|
||||||
|
```
|
||||||
|
|
||||||
|
The service currently uses the upstream LinuxServer image:
|
||||||
|
|
||||||
|
```text
|
||||||
|
lscr.io/linuxserver/calibre-web:latest
|
||||||
|
```
|
||||||
|
|
||||||
|
No custom Docker image is required right now. Gitea stores the Compose setup and documentation; the universal Watchtower instance on the NAS updates the upstream image.
|
||||||
|
|
||||||
|
## NAS Paths
|
||||||
|
|
||||||
|
Current production paths:
|
||||||
|
|
||||||
|
```text
|
||||||
|
Compose path: /volume2/docker/calibreweb/docker-compose.yml
|
||||||
|
Books: /volume1/calibreweb/data/books
|
||||||
|
Config: /volume1/calibreweb/data/config
|
||||||
|
```
|
||||||
|
|
||||||
|
The book library and Calibre-Web config stay on the NAS. They are mounted into the container and must not be committed to Git.
|
||||||
|
|
||||||
|
## Current Container
|
||||||
|
|
||||||
|
```text
|
||||||
|
Container: calibre-web
|
||||||
|
Image: lscr.io/linuxserver/calibre-web:latest
|
||||||
|
Port: 8083 -> 8083
|
||||||
|
TZ: Europe/Berlin
|
||||||
|
PUID: 1000
|
||||||
|
PGID: 1000
|
||||||
|
```
|
||||||
|
|
||||||
|
## Deploy On NAS
|
||||||
|
|
||||||
|
From the NAS:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
cd /volume2/docker/calibreweb
|
||||||
|
cp .env.example .env
|
||||||
|
nano .env
|
||||||
|
docker compose config
|
||||||
|
docker compose up -d
|
||||||
|
docker ps --filter "name=calibre-web" --format "table {{.Names}}\t{{.Image}}\t{{.Ports}}\t{{.Status}}"
|
||||||
|
```
|
||||||
|
|
||||||
|
## Watchtower
|
||||||
|
|
||||||
|
The existing universal Watchtower service should remain responsible for updates. Do not create a second project-specific Watchtower unless explicitly requested.
|
||||||
|
|
||||||
|
Manual one-time check:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -v /volume2/docker/watchtower/config.json:/config.json:ro containrrr/watchtower --run-once
|
||||||
|
```
|
||||||
|
|
||||||
|
## Notes
|
||||||
|
|
||||||
|
- A wrong `/books` mount can make the library look empty even when the files still exist.
|
||||||
|
- A wrong `/config` mount can make Calibre-Web start like a fresh install.
|
||||||
|
- Always verify mounts before recreating the container.
|
||||||
|
|
||||||
|
## Source Of Truth
|
||||||
|
|
||||||
|
The committed `docker-compose.yml` was copied from the live NAS compose file at:
|
||||||
|
|
||||||
|
```text
|
||||||
|
/volume2/docker/calibreweb/docker-compose.yml
|
||||||
|
```
|
||||||
|
|
||||||
|
Only documentation and `.env.example` were added around it.
|
||||||
18
docker-compose.yml
Normal file
18
docker-compose.yml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
services:
|
||||||
|
|
||||||
|
calibre-web:
|
||||||
|
image: lscr.io/linuxserver/calibre-web:latest
|
||||||
|
container_name: calibre-web
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
environment:
|
||||||
|
- PUID=${PUID:-1000}
|
||||||
|
- PGID=${PGID:-10}
|
||||||
|
- TZ=${TZ:-Europe/Berlin}
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- ${BOOKS_PATH:-/volume1/calibreweb/data/books}:/books
|
||||||
|
- ${CONFIG_PATH:-/volume1/calibreweb/data/config}:/config
|
||||||
|
|
||||||
|
ports:
|
||||||
|
- "${APP_PORT:-8083}:8083"
|
||||||
Reference in New Issue
Block a user