This is an old revision of the document!
Calibre Web Automated
CalibreWebAutomated (CWA) Making Calibre-Web your dream, all-in-one self-hosted digital library solution. Provide Calibre with CalibreWeb together to have a perfect e-book management platform.
Installation
As usual, you need to create the cwa user but be careful to assign it to the media group so that it can access all the books of your collection:
useradd -d /data/daemons/cwa -m -g media cwa
You will need also the proper folders setup:
mkdir /data/Books/cwa_config mkdir /data/Books/cwa_ingest mkdir /data/Books/library mkdir /data/Books/cwa_plugins chown cwa:media -R /data/Books/*
Then, as user cwa, create the following docker compose yaml (see here):
Set a proper port (7083)for your needs, one that is free from all your other services. Double check the various volumes to point to your media collection properly. Also set your TimeZone (TZ) appropriately.
Pull the images:
su - cwa
podman compose pull
Reverse Proxy
This is my recomended setup for NGINX:
- cwa.conf
server { server { server_name books.mydomain.com; listen 8443 ssl; listen 443 ssl; access_log /var/log/nginx/books.mydomain.com_access_log main; error_log /var/log/nginx/books.mydomain.com_error_log info; location / { proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header Host $host; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; proxy_http_version 1.1; proxy_pass http://127.0.0.1:7083; proxy_redirect http:// https://; } include com.mydomain/certbot.conf; }
Unfortunately CWA at this time does not support yet sub-paths, so you will need to host it on a subdomain.
Autostart
To start it, and set it up on boot, as usual follow my indications Using Containers on Gentoo, so link the user-containers init script:
ln -s /etc/init.d/user-containers /etc/init.d/user-containers.cwa
and create the following config file:
- /etc/conf.d/user-containers.cwa
USER=cwa DESCRIPTION="The cwa ebook server"
Add the service to the default runlevel and start it now:
rc-update add user-containers.cwa default rc-service user-containers.cwa start
Upgrade
Since it's using pdoman, stop the service then, as user cwa, run:
podman compose pull
and restart the service.