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

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