Backuppc docker file

This commit is contained in:
Przemek Grondek 2017-08-05 00:20:12 +02:00
parent be4e5e779e
commit 49eadb84f9
2 changed files with 33 additions and 0 deletions

27
backuppc/Dockerfile Normal file
View File

@ -0,0 +1,27 @@
FROM ubuntu:16.04
MAINTAINER Przemek Grondek <github@nerull7.info>
ENV APACHE_RUN_USER www-data
ENV APACHE_RUN_GROUP www-data
ENV APACHE_LOG_DIR /var/log/apache2
ENV APACHE_PID_FILE /var/run/apache2.pid
ENV APACHE_RUN_DIR /var/run/apache2
ENV APACHE_LOCK_DIR /var/lock/apache2
ENV APACHE_LOG_DIR /var/log/apache2
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && \
apt-get install -y backuppc gosu supervisor && \
apt-get clean && \
htpasswd -bB /etc/backuppc/htpasswd backuppc backuppc && \
mkdir -p /var/run/backuppc && \
chown backuppc:backuppc /var/run/backuppc && \
sed -i "s/Alias \/backuppc/Alias \//g" /etc/backuppc/apache.conf
COPY supervisord.conf /
EXPOSE 80
VOLUME ["/etc/backuppc", \
"/var/lib/backuppc"]
CMD ["supervisord", "-n", "-c", "/supervisord.conf"]

View File

@ -0,0 +1,6 @@
[supervisord]
[program:apache2]
command=/usr/sbin/apache2 -DFOREGROUND
[program:backuppc]
command=gosu backuppc /usr/share/backuppc/bin/BackupPC