What is docker-svnserve?
docker-svnserve is a unofficial docker image for the svnserve daemon.
There are already a number of avaliable docker images for subversion and svnserve hosting. But most of them either are:
- Too involved; Containers shouldn't be like aplications themselves with configuration in environment variables, etc. Instead, images should be extensible so other users can create their own images with customizations, based on yours.
- Bloated; Based on heavy fat-container base images.
- Don't handle signals properly, forcing docker to send
SIGKILLto the process.
How to use this image
The image is intented to run as a daemon; it exposed the default svnserve port (
3690) and a single volume at
svnserve uses as it's root. A container based on this image could be created as:
docker run \ --detatch \ --name svnserve \ --restart always \ --expose 3690:3690/tcp \ --volume /var/opt/svn:/var/opt/svn:rw \ gcscaglia/svnserve:latest
With the above comand,
- run in daemon mode
- listen on the standard port on all host's interfaces
- (re)start with the system
- serve repositories from
/var/opt/svnin the host's filesystem.
In order to create, manage and backup repositories, two approaches can be combined:
- Directly accessing the repositories on the filesystem. This should be enough for cold-bakups and user management depending on how you autenticate your users.
- By running your commands inside the container (using
docker-exec). This allows access to svn adminstration tools