saltstack-formulas / bind-formula

http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
29 stars 117 forks source link

feat: allow customization of a postrotate script #153

Open ekacnet opened 1 year ago

ekacnet commented 1 year ago

You need to signal to bind to reload log files after rotating them, doing rndc reconfig is a good way of doing so.

This change allows you to actually have that in the generated logrotate configuration

PR progress checklist (to be filled in by reviewers)


What type of PR is this?

Primary type

Secondary type

Does this PR introduce a BREAKING CHANGE?

No.

Related issues and/or pull requests

Describe the changes you're proposing

Allow the logrotate config to have a postrotate script. When using logrotate without telling bind to reload, it will continue to write to the same file.

Pillar / config required to test the proposed changes

logrotate: postrotate_script: > rndc reconfig &>/dev/null || true

Debug log showing how the proposed changes work

Documentation checklist

Testing checklist

Additional context

ekacnet commented 1 year ago

@javierbertoli is there anything blocking here ?