Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add mail_default_enable param #49

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

joshuabaird
Copy link
Contributor

This adds a "mail_default_enable" param which defaults to true which is typical for most deployments. I know this likely needs test updates as well but I wanted initial feedback on this option. It's a necessary parameter for my environment.

@ghoneycutt
Copy link
Owner

It seems that the code already logs mail with mail.* -/var/log/maillog. Do you want the ability to turn that off? That is what this patch seems to be providing. If so, it would be better to make the destination configurable. That way you could do another file, another host, or discard it with ~.

@ghoneycutt
Copy link
Owner

btw: do you know what the dash in front of /var/log/maillog is for? having a hard time finding it in the docs, though I know it is logging mail.* correctly.

@joshuabaird
Copy link
Contributor Author

Yeah, I need the ability to turn it off. I have servers that have several instances of postfix running which requires me to drop individual rsyslog.d configurations for each of them. The global (default) mail.* in rsyslog.conf overrides these.

The dash "-" disables sync()'s after writing out each line.

@ghoneycutt
Copy link
Owner

You could add $mail_target and change the template to mail.* <%= @mail_target %> and in your configuration set $mail_target = '~'.

Would that work for you? I think it would give us more flexibility.

@ghoneycutt
Copy link
Owner

@joshuabaird Hi Josh, just checking in on this PR as it seems to have gone cold. Does my suggestion work for you? I could code it if necessary, but want to ensure it is going to meet your needs.

@joshuabaird
Copy link
Contributor Author

Sorry - been busy here. I do think that would work fine, although I haven't personally tested the functionality.

@jyaworski
Copy link

Will this be picked back up?

@ghoneycutt
Copy link
Owner

@jyaworski would you like to pick this up?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants