digibib / koha-docker

Koha docker image builders
MIT License
53 stars 18 forks source link

Koha Docker Container (WILL BE DEPRECATED SOON)

This repo is no longer maintained by Deichman (Oslo Public Library)

If anyone wants to keep on developing this, we'd happily transfer ownership.

If interested in seeing our customized version of the Koha project, head to OPL repo.

It includes a koha + mysql setup with a heavily customized version of Koha, of course keeping the GPL license.

Old info

This project builds a Docker image containg an installation of the library system Koha.

More documentation can be found on project wiki

Development Quickstart for Deichman

This is documentation on the development setup used in Deichman, but should be general enough to be used by anyone.

Clone the two projects

1. The Koha codebase

https://github.com/Koha-Community/Koha (upstream) the community code

git clone https://gitlab.deichman.no/digibib/koha

We keep master in sync with upstream and a local branch for each release with all our local patches on top (eg. release_17.11.01)

git checkout release_17.11.01

2. The Koha Docker project

https://gitlab.deichman.no/digibib/koha (origin) deichman fork with local patches

This is the project for setting up Koha using docker in the various environments:

git clone https://gitlab.deichman.no/digibib/koha-docker

3. Run Development

TODO: use Makefile instead

Build development docker image

KOHAPATH must point to koha-docker root dir

source docker-compose.env && KOHAPATH=.. docker-compose -f common.yml -f dev.yml build koha_dev

Run development container

KOHAPATH must point to koha-docker root dir

REPO must point to koha code repo

source docker-compose.env && KOHAPATH=..  \
  docker-compose -f common.yml -f dev.yml run --rm --volume=/home/to/koha/repo:/kohadev/kohaclone --publish=8081:8081 koha_dev

4. Enter container

Container will have an autogenerated name (find it with docker ps) if not started with --name

Admin pages are at localhost:8081, with default admin (admin/secret) login

docker exec -it dockercompose_koha_dev_run_1 bash

5. Useful commands inside container

It is a debian jessie distro, koha source code is mounted in /kohadev/kohaclone

A lot of env vars exist used to configure system (use env for overview)

koha-mysql name
KOHA_CONF=/etc/koha/sites/name/koha-conf.xml PERL5LIB=. perl t/db_dependent/api/v1/illrequests.t