[英]How to configure rsyslog inside docker image centos 8
I'm building a docker image based on centos
that contains a postfix
configuration.我正在基于包含postfix
配置的centos
构建一个 docker 图像。 However, it's not working correctly, so I'm trying to debug it.但是,它无法正常工作,所以我正在尝试调试它。 I want to enable rsyslog, so I can see the logging.我想启用 rsyslog,这样我就可以看到日志记录。
However, the default rsyslog.conf
does not log anything.但是,默认的rsyslog.conf
不记录任何内容。 What is the proper way to set-up local logging for rsyslog in a centos8 docker image?在 centos8 docker 图像中为 rsyslog 设置本地日志记录的正确方法是什么?
This mini config seems to work这个迷你配置似乎有效
module(
load="imuxsock"
SysSock.Use="on"
)
#### RULES ####
mail.* /var/log/mail
*.* /var/log/messages
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.