postfix

instrumentisto/postfix Docker Image

instrumentisto
自动构建

Postfix邮件传输代理(MTA)的Docker镜像,用于路由和投递电子邮件,替代Sendmail,具备快速、易管理和安全的特点,支持多种配置方式及Alpine基础镜像。

11 次收藏下载次数: 0状态:自动构建维护者:instrumentisto仓库类型:镜像最近更新:

Postfix Docker镜像

https://github.com/just-containers/s6-overlay

支持的标签及对应的Dockerfile链接

  • 3.1.3, 3.1, 3, latest https://github.com/instrumentisto/postfix-docker-image/blob/master/debian/Dockerfile
  • 3.1.3-alpine, 3.1-alpine, 3-alpine, alpine https://github.com/instrumentisto/postfix-docker-image/blob/master/alpine/Dockerfile

什么是Postfix?

Postfix是一款免费开源的邮件传输代理(MTA),用于路由和投递电子邮件,旨在替代Sendmail MTA。

它是由Wietse Venema开发的邮件服务器,最初在http://www.research.ibm.com作为广受欢迎的Sendmail程序的替代方案。现在Wietse在Google继续支持Postfix的开发。

Postfix力求快速、易于管理且安全。其外部接口具有Sendmail风格,但内部实现完全不同。

http://www.postfix.org

如何使用此镜像

运行Postfix只需挂载配置文件并启动容器:

bash
docker run -d -p 25:25 -v /my/main.cf:/etc/postfix/main.cf docker.xuanyuan.run/instrumentisto/postfix

配置

您可以通过以下两种方式之一配置Postfix(不可同时使用):

  1. 增量配置文件
    将您的配置文件(必须以.cf结尾)放入/etc/postfix/main.cf.d/和/etc/postfix/master.cf.d/目录。容器启动时,这些文件将应用于默认Postfix配置。

    bash
    docker run -d -p 25:25 \
               -v /my/main.cf:/etc/postfix/main.cf.d/10-custom.cf:ro \
               -v /my/master.cf:/etc/postfix/master.cf.d/10-custom.cf:ro \
           docker.xuanyuan.run/instrumentisto/postfix
    

    此方式适用于只需对默认配置进行少量修改,或希望将不同配置部分分开保存的场景。

  2. 完整配置替换
    将您的配置文件(main.cf和master.cf)放入/etc/postfix/目录,完全替换镜像提供的默认配置文件。

    bash
    docker run -d -p 25:25 \
               -v /my/main.cf:/etc/postfix/main.cf:ro \
               -v /my/master.cf:/etc/postfix/master.cf:ro \
           docker.xuanyuan.run/instrumentisto/postfix
    

    此方式适用于更方便一次性指定完整配置,而非修改默认选项的场景。

默认配置查看

要查看此Docker镜像的默认Postfix配置,请运行:

bash
# 查看main.cf
docker run --rm docker.xuanyuan.run/instrumentisto/postfix postconf

# 查看master.cf
docker run --rm docker.xuanyuan.run/instrumentisto/postfix postconf -M

镜像版本说明

X

Postfix主版本X的最新版本。

X.Y

Postfix次版本X.Y的最新版本。

X.Y.Z

Postfix具体版本X.Y.Z。

alpine

基于流行的http://alpinelinux.org(可在https://hub.docker.com/_/alpine中获取)。Alpine Linux比大多数发行版基础镜像小得多(约5MB),因此生成的镜像更精简。
当需要最小化最终镜像大小时,强烈推荐此变体。需要注意的是它使用http://www.musl-libc.org而非http://www.etalabs.net/compare_libcs.html,某些软件可能因libc依赖深度而出现问题,但大多数软件无此问题,因此这是一个安全的选择。

重要提示

由于Postfix仅将日志写入syslog,容器内运行syslogd进程作为第二个辅助进程,并由https://github.com/just-containers/s6-overlay提供的http://skarnet.org/software/s6/overview.html进行管理。

日志

此镜像的syslogd进程配置为将所有日志写入/dev/stdout。
如需更改此行为,只需挂载您自己的/etc/syslog.conf文件并设置所需的日志规则。

s6-overlay

此镜像包含https://github.com/just-containers/s6-overlay,您可根据需要使用其提供的所有https://github.com/just-containers/s6-overlay#usage。

许可证

Postfix本身采用http://www.postfix.org/IBM-Public-License-1.0.txt。
Postfix Docker镜像采用https://github.com/instrumentisto/postfix-docker-image/blob/master/LICENSE.md。

问题反馈

我们无法查看DockerHub上的评论,因此请勿使用评论报告问题或提问。
如有任何问题,请通过https://github.com/instrumentisto/postfix-docker-image/issues联系我们。

镜像拉取方式

您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。

轩辕镜像加速拉取命令点我查看更多 postfix 镜像标签

docker pull docker.xuanyuan.run/instrumentisto/postfix:<标签>

DockerHub 原生拉取命令

docker pull instrumentisto/postfix:<标签>
专业版 · 高速稳定拉取镜像
50GB 仅 ¥8/年
高速镜像下载在线技术支持专业版保障服务可用付费会员免广告