This is a Dockerfile for I, Librarian. Please, Look at the following instructions.
If you do not already have an I, Librarian database, you must create a blank library folder ${DATA_PATH}
to initiate the library on the host before to run the container, and set up its ownership correctly.
mkdir ${DATA_PATH}
sudo chown 33:33 ${DATA_PATH}
sudo docker run -d -p 8080:80 \
-v ${DATA_PATH}:/app/data \
-v /etc/localtime:/etc/localtime:ro \
--name=i-librarian \
cgrima/i-librarian
Create your docker-compose.yml file such as
version: "2"
services:
app:
image: cgrima/i-librarian
privileged: true
ports:
- "8080:80"
volumes:
- ${DATA_PATH}:/app/data
- /etc/localtime:/etc/localtime:ro
Then, start docker-compose
docker-compose up -d
Open http://localhost:8080 on your web browser and follow instructions.
Migration from I, Librarian 4.10 to 5.*
Note: The 4.10 database folder was called library
. It is called data
in 5.*.
- Stop your 4.10 I, Librarian container, i.e.
docker-compose stop i-librarian
- Backup your 4.10
library/
folder. - Remove your 4.10 I, Librarian container, i.e.
docker-compose rm i-librarian
. - Rebuild the I, Librarian image from latest source, i.e.
docker-copomse up -d
. - Build and Launch your new 5.* I, Librarian container following one of the statements above but add you former 4.10 database folder as volume,
i.e.
-v ${LIBRARY_PATH}:/app/library
. - Connect to http://localhost:8080 and follow the migration instructions (the library folder to migrate is
/app/library
).
Simply stop, remove, and launch your container again. With docker-compose:
docker-compose down
docker-compose up -d
If you have rights/permissions issues with the library folder try to add the --privileged=true
option to the docker run command.