linuxserver / docker-calibre

GNU General Public License v3.0
339 stars 62 forks source link

Calibre config files aren't generated #48

Closed JVT038 closed 3 years ago

JVT038 commented 3 years ago

linuxserver.io

I recently updated calibre to the latest version and when I opened calibre in the browser, it showed me the set up UI and calibre was restored to it's default settings. The entire configurations was restored to default and when I added a plugin and restarted calibre to load it, the plugin was gone and I had to set everything up again.

Expected Behavior

Calibre should've just behaved like normal, without resetting the configurations.

Current Behavior

Every time calibre restarts, the configuration is restored to default settings. The configuration files of Calibre aren't generated; I teseted it, by pointing /config to an empty folder, and everything was generated like it's supposed to, except the calibre configuration files in /config/.config/calibre.

Steps to Reproduce

  1. Launch the latest version of calibre (v5.16.1-ls111 in my case)
  2. Install a plugin or make some changes to the configurations
  3. Restart calibre
  4. See how the configurations have been restored to default

Environment

OS: Docker on Synology NAS DS918+ CPU architecture: x86_64/arm32/arm64 How docker service was installed:

Docker is installed via the Package Manager of Synology

Command used to create docker container (run/create/compose/screenshot)

calibre: image: ghcr.io/linuxserver/calibre:version-v5.16.0 container_name: calibre environment:

  • PUID=$PUID
  • PGID=$PGID
  • TZ=$TZ volumes:
  • $DOCKERDIR/calibre/server:/config
  • $MEDIADIR/ebooks:/data

    - $USB:/usb # als je een E-Reader aan wilt sluiten, haal de comment weg

    ports:

  • 8084:8080 # voor de guacamole ui
  • 8085:8081 # voor de content server web gui
  • 9090:9090 # voor de wireless device server restart: always

For now, I have downgraded to version-v5.16.0, since that version doesn't have this bug.

github-actions[bot] commented 3 years ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

aptalca commented 3 years ago

A fix will be pushed shortly

Torqu3Wr3nch commented 3 years ago

How confident are we that this is fixed? I'm hitting this after the update to v5.16.1-ls112. Had to roll back to my last known-good state at ls109.

aptalca commented 3 years ago

It fixed it on my local install

The issue was, we added a feature to make calibre access system environment vars. That had an unexpected effect due to calibre seeing the var HOME=/root and looking in there for app settings. Setting HOME=/config restored the previous behavior

Torqu3Wr3nch commented 3 years ago

Figured it out (and thanks for the response; I saw that in your commit).

I recently switched to using Portainer instead of the CLI to maintain my containers. Turns out that Portainer has this nasty little problem where it stores the ENV variables set during image building/Dockerfile and never lets go of them, unless you go in and explicitly delete them yourself.

https://github.com/portainer/portainer/issues/2952

https://github.com/portainer/portainer/issues/4142

Deleting out the HOME=/root ENV fixed everything.

aptalca commented 3 years ago

Glad you figured it out. That's one of the reasons we don't recommend portainer. We highly recommend docker compose, and we provide yaml samples for all of our images. See here: https://docs.linuxserver.io/general/docker-compose