fork 0k-charms
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

31 lines
761 B

FROM debian:jessie
MAINTAINER Valentin Lab <valentin.lab@kalysto.org>
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install --force-yes -y --no-install-recommends openssh-server sudo rsync && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
COPY ./src/usr/local/sbin/* /usr/local/sbin/
## New user/group rsync/rsync with home dir in /var/lib/rsync
RUN mkdir -p /var/lib/rsync && \
groupadd -r rsync && \
useradd -r rsync -d /var/lib/rsync -g rsync && \
chown rsync:rsync /var/lib/rsync
## Allow rsync to access /var/mirror
COPY /src/etc/sudoers.d/rsync /etc/sudoers.d/rsync
RUN chmod 440 /etc/sudoers.d/*
RUN mkdir /var/run/sshd
COPY ./entrypoint.sh /entrypoint.sh
EXPOSE 22
ENTRYPOINT [ "/entrypoint.sh" ]