FAQ Category: Contributing

Getting all the development dependencies and a working copy for LedgerSMB can be time consuming and complex. However, using our Docker Compose infrastructure reduces this to four simple steps:

  1. Install Docker
  2. Install Docker Compose
  3. Clone the LedgerSMB repository from GitHub
  4. Clone the LedgerSMB Development Docker repository from GitHub

(And start the infrastructure from the docker compose file.)


The example below works on Debian Stretch:

### Install Docker

$ sudo apt-get install \
     apt-transport-https \
     ca-certificates \
     curl \
     gnupg2 \
$ curl -fsSL https://download.docker.com/linux/$(. /etc/os-release; echo "$ID")/gpg | sudo apt-key add -
$ sudo add-apt-repository \
   "deb [arch=amd64] https://download.docker.com/linux/$(. /etc/os-release; echo "$ID") \
   $(lsb_release -cs) \
$ sudo apt-get update
$ sudo apt-get install docker-ce

### Install Docker Compose

# Check the latest release at https://github.com/docker/compose/releases/ (and replace 1.17.0 with it)
sudo curl -L https://github.com/docker/compose/releases/download/1.17.0/docker-compose-`uname -s`-`uname -m` \
            -o /usr/local/bin/docker-compose
$ sudo chmod +x /usr/local/bin/docker-compose

### (Optionally) Install docker compose bash completion
$ sudo curl -L https://raw.githubusercontent.com/docker/compose/1.17.0/contrib/completion/bash/docker-compose \
            -o /etc/bash_completion.d/docker-compose

### Clone the LedgerSMB repository from GitHub (checks out 'master' branch)
$ git clone https://github.com/ledgersmb/LedgerSMB.git ledgersmb

### Clone the LedgerSMB Development Docker repository from GitHub
$ clone https://github.com/ledgersmb/ledgersmb-dev-docker.git lsmb-dev-docker

### Pull the latest infrastructure from Docker Hub using Docker Compose
$ LSMB_DEV_VERSION=master docker-compose -f ../lsmb-dev-docker/docker-compose.yml pull


At this point you are set up to start developing and testing LedgerSMB; in order to test your changes in a running LedgerSMB instance, run:

$ cd ledgersmb
$ lSMB_DEV_VERSION=master docker-compose -f ../lsmb-dev-docker/docker-compose.yml up -d

This command starts the container infrastructure (using the names "lsmb-master-devel" and "postgres-lsmb-master-devel" for the LedgerSMB and PostgreSQL containers respectively), taking the sources in the current directory (ledgersmb) to run the application.


File permissions

You may run into problems with file permissions if you want to run commands inside the containers which try to modify your local repository. You will need to either recursively set the file ownership to this user in your local tree, assign liberal 0777 (directory) and 0666 (file) permissions or execute the commands inside the container as root.

Example using www-data user, after you fix your file permissions:

docker exec -ti lsmb-master-devel bash
www-data@90451823cb57:/srv/ledgersmb$ make dojo

Example using root inside the container:

docker exec -ti --user=root lsmb-master-devel bash

Cache issues

The container is set up with template caching enabled. This means that you'll need to restart the container after code changes to see them. This is a simple:

$ LSMB_DEV_VERSION=master docker-compose -f ../lsmb-dev-docker/docker-compose.yml restart

Supported versions

At the time of writing (November 2017), the development container infrastructure only supports development of 1.5 and master/1.6 versions of LedgerSMB.


# diff -u "original file" "new edited file" > “diff file”

Submit your patches ( “diff file” through the Sourceforge project tracker. If you are going to do somewhat largish changes, it's best to discuss how to do them on the developers list. That increases chances for acceptance which is in general the best solution for you and the lsmb community.

At least three active committers and many more developers.

The ledger-smb-devel mailing list have 196 subscribers (22. Mai 2012).
Check the mailing lists at https://sourceforge.net/p/ledger-smb/mailman/

Community: /following-and-contributing

192 subscribers (1. Nov 2011)

We ask that all IRC members follow the Ubuntu Code of Conduct.

We also ask that you always use a paste site when pasting more than 2-3 lines. Paste sites include: