ARG ALPINE_VERSION=3.18.3 ARG BASE_IMAGE=gitea.nulo.in/sutty/monit FROM ${BASE_IMAGE}:${ALPINE_VERSION} LABEL org.opencontainers.image.authors="f@sutty.nl" ENV MAX_MEMORY=100mb RUN echo "bind 127.0.0.1 ::1" >> /etc/redis.conf RUN sed -re "/^save \"\"/d" \ -e "s/^(appendonly) .*/\1 yes/" \ -e "s/^(maxmemory-policy) .*/\1 volatile-ttl/" \ -e "s|^(dir) .*|\1 /var/lib/redis|" \ -i /etc/redis.conf RUN apk add --no-cache rspamd rspamd-client rspamd-proxy rspamd-controller RUN install -dm 755 /etc/rspamd/local.d RUN install -dm 750 -o rspamd -g rspamd /var/lib/rspamd RUN install -dm 750 -o redis -g redis /var/lib/redis COPY ./dkim_signing.conf /etc/rspamd/local.d/dkim_signing.conf COPY ./redis.conf /etc/rspamd/local.d/redis.conf COPY ./worker-proxy.inc /etc/rspamd/local.d/worker-proxy.inc COPY ./worker-normal.inc /etc/rspamd/local.d/worker-normal.inc COPY ./worker-controller.inc /etc/rspamd/local.d/worker-controller.inc COPY ./options.inc /etc/rspamd/local.d/options.inc COPY ./logging.inc /etc/rspamd/local.d/logging.inc COPY ./classifier-bayes.conf /etc/rspamd/local.d/classifier-bayes.conf COPY ./local_addrs /etc/rspamd/local.d/maps.d/local_addrs COPY ./monit.conf /etc/monit.d/rspamd.conf EXPOSE 11332 EXPOSE 11333 EXPOSE 11334 VOLUME "/var/lib/redis" VOLUME "/var/lib/rspamd"