diff options
author | Linus Nordberg <linus@nordberg.se> | 2015-04-01 22:14:13 +0200 |
---|---|---|
committer | Linus Nordberg <linus@nordberg.se> | 2015-04-01 22:14:13 +0200 |
commit | 4caf30c37e986c0f8a70591571d1e4c9fd94ce42 (patch) | |
tree | 7a7f43aaeba5c1d17db61d0914d3da436c2ccdd4 /packaging/docker/catlfish-merge/Dockerfile | |
parent | 4860fff216892010a997547b0fa19cd4505cb804 (diff) |
Dockerfile for merge, first cut.
Diffstat (limited to 'packaging/docker/catlfish-merge/Dockerfile')
-rw-r--r-- | packaging/docker/catlfish-merge/Dockerfile | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/packaging/docker/catlfish-merge/Dockerfile b/packaging/docker/catlfish-merge/Dockerfile new file mode 100644 index 0000000..82b46fa --- /dev/null +++ b/packaging/docker/catlfish-merge/Dockerfile @@ -0,0 +1,35 @@ +# Docker file for catlfish merge. +# +# $ docker run \ +# -v /etc/catlfish:/usr/local/etc/catlfish \ +# -v /var/local/db/catlfish-merge:/var/local/db/catlfish-merge \ +# catlfish-merge + +FROM base +RUN apt-get update +RUN echo 'debconf debconf/frontend select noninteractive' | debconf-set-selections +RUN apt-get -y -q install python-ecdsa python-yaml + +WORKDIR /usr/local/src +RUN git clone https://git.nordu.net/catlfish.git + +# Config dir and database dir are mounted from host using `-v' to +# 'docker run'. +VOLUME /usr/local/etc/catlfish +VOLUME /var/local/db/catlfish-merge + +# We run from /var/run/catlfish. +RUN mkdir /var/run/catlfish +RUN chgrp daemon /var/run/catlfish +RUN chmod 775 /var/run/catlfish + +# Copy merge.sh. +RUN mkdir -p /usr/local/catlfish/bin +ADD merge.sh /usr/local/catlfish/bin/ + +# Don't run as root. +USER daemon + +# Start merge.sh +WORKDIR /var/run/catlfish +CMD ["/usr/local/catlfish/bin/merge.sh", "300", "1200", "/var/local/db/catlfish-merge"] |