This is an attempt to make a Koha docker image. I am by no means an expert in Docker or Github, I just saw all the broken Github repositories when I was trying to test Koha, and here we are. My goal was to find and set up something for book inventory, though this may be a bit overkill for personal use.
This is meant to be self-hosted, and used in your network. I have not done anything to harden this container.
Still a work in progress.
Start the container by:
git clone https://github.com/sukuoru/koha-docker-ubuntu
cd koha-docker-ubuntu
- modify docker-compose / dockerfile as needed
docker compose up -d
- navigate to docker-ip:3025
In the docker-compose.yml file, you can change a few things, if needed.
NO_MEMCACHED
can be set to true to NOT install memcached
SLEEP
affects how long we will wait for the database server/rabbitmq to be available before trying again
Most importantly:
TIMEZONE
to set the Koha's timezone. Uses PHP format:
https://www.php.net/manual/en/timezones.php
INSTALL_LANG
to add a language translation. Be sure to uncomment it if you need this.
https://wiki.koha-community.org/wiki/Koha_on_Debian#Additional_configuration
In the koha-conf.xml you can provide your own encryption_key .
This can be generated by runing pwgen 32 in the container, or through other means.
-
Version In the dockerfile, line 11 can be changed to which version of Koha you would like you install.
Stable is not recommended, per Koha.
I have tested both stable and 24.05. See here for more detail:
https://wiki.koha-community.org/wiki/Koha_on_Debian#Choosing_what_Koha_release_to_follow_-_a_version_number_or_a_codename -
Checking for errors If the Koha container starts, but you are not able to access it,
the Apache error logs can give good direction.
docker exec -ti koha /bin/bash
tail -f /var/log/apache2/error.log