Dockerfile 1.0 KB

1234567891011121314151617181920212223242526
  1. FROM docker.io/alpine:3.19.0
  2. # http://www.postfix.org/announcements.html
  3. # https://git.alpinelinux.org/aports/log/main/postfix?h=3.19-stable
  4. ARG POSTFIX_PACKAGE_VERSION=3.8.4-r0
  5. # http://www.postfix.org/postconf.5.html#tls_append_default_CA
  6. # https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/
  7. # https://gitlab.alpinelinux.org/alpine/ca-certificates/-/commits/master
  8. # https://git.alpinelinux.org/aports/log/main/ca-certificates?h=3.19-stable
  9. ARG MOZILLA_CA_CERT_STORE_PACKAGE_VERSION=20230506-r0
  10. RUN apk add --no-cache \
  11. ca-certificates=$MOZILLA_CA_CERT_STORE_PACKAGE_VERSION \
  12. postfix=$POSTFIX_PACKAGE_VERSION \
  13. && postconf -evv tls_append_default_CA=no `# default, but better be safe`
  14. # http://www.postfix.org/MAILLOG_README.html
  15. RUN postconf -F | grep -E '^postlog/unix-dgram/service = postlog$' \
  16. && postconf -evv maillog_file=/dev/stdout \
  17. && postfix check
  18. # http://www.postfix.org/postconf.5.html#queue_directory
  19. VOLUME /var/spool/postfix
  20. EXPOSE 25/tcp
  21. COPY postfix.sh /
  22. CMD ["/postfix.sh"]