2016-12-10 03:39:02 +08:00
|
|
|
From ubuntu:xenial
|
|
|
|
MAINTAINER Andre Peters <andre.peters@servercow.de>
|
|
|
|
|
|
|
|
ENV DEBIAN_FRONTEND noninteractive
|
2016-12-23 17:27:48 +08:00
|
|
|
ENV LC_ALL C
|
2016-12-10 03:39:02 +08:00
|
|
|
|
2016-12-23 17:27:48 +08:00
|
|
|
RUN dpkg-divert --local --rename --add /sbin/initctl \
|
|
|
|
&& ln -sf /bin/true /sbin/initctl \
|
|
|
|
&& dpkg-divert --local --rename --add /usr/bin/ischroot \
|
|
|
|
&& ln -sf /bin/true /usr/bin/ischroot
|
|
|
|
|
|
|
|
RUN apt-get update
|
|
|
|
RUN apt-get -y install dovecot-common \
|
|
|
|
dovecot-core \
|
|
|
|
dovecot-imapd \
|
|
|
|
dovecot-lmtpd \
|
|
|
|
dovecot-managesieved \
|
|
|
|
dovecot-sieve \
|
|
|
|
dovecot-mysql \
|
|
|
|
dovecot-pop3d \
|
|
|
|
dovecot-dev \
|
|
|
|
wget \
|
|
|
|
curl \
|
|
|
|
build-essential \
|
|
|
|
autotools-dev \
|
|
|
|
automake
|
2016-12-10 03:39:02 +08:00
|
|
|
|
2016-12-13 19:26:10 +08:00
|
|
|
WORKDIR /tmp
|
|
|
|
RUN wget http://hg.dovecot.org/dovecot-antispam-plugin/archive/tip.tar.gz -O - | tar xvz \
|
|
|
|
&& cd /tmp/dovecot-antispam* \
|
|
|
|
&& ./autogen.sh \
|
|
|
|
&& ./configure --prefix=/usr \
|
|
|
|
&& make \
|
|
|
|
&& make install
|
2016-12-10 03:39:02 +08:00
|
|
|
|
2016-12-15 17:07:09 +08:00
|
|
|
COPY ./rspamd-pipe /usr/local/bin/rspamd-pipe
|
|
|
|
COPY ./docker-entrypoint.sh /
|
2016-12-13 19:26:10 +08:00
|
|
|
|
|
|
|
RUN chmod +x /usr/local/bin/rspamd-pipe
|
2016-12-23 17:27:48 +08:00
|
|
|
|
2016-12-10 03:39:02 +08:00
|
|
|
RUN groupadd -g 5000 vmail
|
|
|
|
RUN useradd -g vmail -u 5000 vmail -d /var/vmail
|
|
|
|
|
|
|
|
EXPOSE 24 10001
|
|
|
|
|
2016-12-15 17:07:09 +08:00
|
|
|
ENTRYPOINT ["/docker-entrypoint.sh"]
|
2016-12-10 03:39:02 +08:00
|
|
|
CMD ["/usr/sbin/dovecot", "-F"]
|
2016-12-23 17:27:48 +08:00
|
|
|
|
|
|
|
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|