2017-09-06 08:46:01 +00:00
|
|
|
#FROM alpine:latest as builder
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#ENV PROFTP_VERSION v1.3.6
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#ADD /rootfs /
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#RUN apk add --no-cache libressl openssh-client tar gcc make g++ openldap-dev zlib-dev file
|
|
|
|
#RUN mkdir /tmp/proftpd
|
|
|
|
#RUN wget -qO- https://github.com/proftpd/proftpd/archive/$PROFTP_VERSION.tar.gz | tar -xz -C /tmp/proftpd --strip 1
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#WORKDIR /tmp/proftpd
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#RUN ./configure --with-modules=mod_ldap:mod_sftp --disable-wtmp
|
|
|
|
#RUN patch -p1 -i /musl_mempcpy.patch
|
|
|
|
#RUN make && make install
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
FROM registry.gitlab.com/thallian/docker-confd-env:master
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
#COPY --from=builder /usr/local/sbin/proftpd /usr/sbin/proftpd
|
|
|
|
#COPY --from=builder /usr/local/lib/proftpd /usr/lib/proftpd
|
|
|
|
|
|
|
|
RUN apk add --no-cache libressl openssh-client openldap zlib
|
|
|
|
RUN apk add --no-cache --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing \
|
|
|
|
proftpd proftpd-mod_ldap proftpd-mod_sftp
|
|
|
|
|
2017-09-06 09:00:17 +00:00
|
|
|
RUN addgroup -g 2222 access
|
2017-09-06 08:46:01 +00:00
|
|
|
RUN addgroup proftpd access
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
RUN rm /etc/proftpd/dhparams.pem
|
2017-09-06 09:03:12 +00:00
|
|
|
RUN mkdir /etc/proftpd/keys/ && mkdir /var/proftpd
|
2017-09-06 09:02:10 +00:00
|
|
|
RUN chown -R proftpd:proftpd /var/proftpd
|
2017-09-06 08:46:01 +00:00
|
|
|
|
|
|
|
ADD /rootfs /
|
|
|
|
|
|
|
|
WORKDIR /
|
2016-10-13 11:52:14 +00:00
|
|
|
|
2017-09-06 08:46:01 +00:00
|
|
|
VOLUME /etc/proftpd/keys /var/lib/ftp/data
|
2017-06-13 13:36:25 +00:00
|
|
|
|
|
|
|
EXPOSE 22
|