From 802fa9cc094dd9dfe7f94f66e4438d56141ea365 Mon Sep 17 00:00:00 2001 From: Arthur Lefebvre Date: Thu, 5 Mar 2026 15:33:10 +0100 Subject: [PATCH] Add docker documentation --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index a086762..3618b75 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,28 @@ Bibliomane is a free server whose main purpose is to track your reading. It is currently in development, and not in a state where it can be used in production. +## Docker + +The docker image is currently not published. So you need to build it : + +`docker build -t bibliomane .` + +Then you can test it by running it directly, redirecting the default port: + +`docker run -p8080:8080 bibliomane` + +You can store image folder, config file and sqlite file in a bind folder to have a persistent instance. For example, if you created a folder `bibliomane_data`: + +`docker run -p8080:8080 --mount type=bind,src=/path/to/bibliomane_data,dst=/opt/bibliomane bibliomane` + +You can also change the image folder path in the container using `-i`. For example, if you have a folder `bibliomane_data/image`: + +`docker run -p8080:8080 --mount type=bind,src=/path/to/bibliomane_data,dst=/opt/bibliomane bibliomane -i /opt/bibliomane/image` + +Or with a volume, for example if you created a volume named `bibliomane_data`: + +`docker run -p8080:8080 --volume bibliomane_data:/opt/bibliomane bibliomane` + ## Generate new accounts on startup `--add-user` or `-a` can be used to create an account on startup. It requires a string following htpasswd format `[username]:[bcrypt hashed password]`.