1
0

Dockerfile 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. # Copyright (c) 2024 Fabian Peter Hammerle
  2. #
  3. # This program and the accompanying materials are made available under the
  4. # terms of the Eclipse Public License 2.0 which is available at
  5. # http://www.eclipse.org/legal/epl-2.0.
  6. #
  7. # SPDX-License-Identifier: EPL-2.0
  8. FROM docker.io/alpine:3.20.3
  9. # http://www.postfix.org/announcements.html
  10. # https://git.alpinelinux.org/aports/log/main/postfix?h=3.20-stable
  11. ARG POSTFIX_PACKAGE_VERSION=3.9.0-r1
  12. # http://www.postfix.org/postconf.5.html#tls_append_default_CA
  13. # https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/
  14. # https://gitlab.alpinelinux.org/alpine/ca-certificates/-/commits/master
  15. # https://git.alpinelinux.org/aports/log/main/ca-certificates?h=3.19-stable
  16. ARG MOZILLA_CA_CERT_STORE_PACKAGE_VERSION=20240705-r0
  17. RUN apk add --no-cache \
  18. ca-certificates=$MOZILLA_CA_CERT_STORE_PACKAGE_VERSION \
  19. postfix=$POSTFIX_PACKAGE_VERSION \
  20. && postconf -evv tls_append_default_CA=no `# default, but better be safe`
  21. # http://www.postfix.org/MAILLOG_README.html
  22. RUN postconf -F | grep -E '^postlog/unix-dgram/service = postlog$' \
  23. && postconf -evv maillog_file=/dev/stdout \
  24. && postfix check
  25. # http://www.postfix.org/postconf.5.html#queue_directory
  26. VOLUME /var/spool/postfix
  27. EXPOSE 25/tcp
  28. COPY postfix.sh /
  29. CMD ["/postfix.sh"]