docker-koreader icon indicating copy to clipboard operation
docker-koreader copied to clipboard

Persist .config/koreader/ when stopping container

Open ryanwwest opened this issue 1 year ago • 2 comments

The instructions suggest creating a docker-compose.yaml with a volume for ./config:/config. But while files I put in ./config/ seem to persist across container restarts, ./config/.config/koreader/ doesn't persist. Is there a way to get this to also persist, including across updates to KOReader?

ryanwwest avatar Apr 27 '24 17:04 ryanwwest

It looks like data is persisted as long as you properly quit KOReader using its UI. I think this is a side effect of when KOReader chooses to save settings changes, as I was testing by enabling/disabling night mode and then immediately quitting and the change wasn't persisting.

I'm guessing there's a way to gracefully shut down a docker-compose container that could include signaling KOReader to save anything? I don't think requiring the user to exit to save some settings is a good solution as then you have to restart the container anyway to get KOReader back and usable.

ryanwwest avatar Apr 27 '24 17:04 ryanwwest

The container can only send SIGTERM to the Koreader process, so I think this need to be handled at the Koreader application. For now I'll add this behavior to the docs.

zephyros-dev avatar Apr 28 '24 04:04 zephyros-dev