Ability to disable reload/HUP of apache/nginx after rotation

Version 1.51

Feature
Finished

New variable: reload_apache_after_rotation=1 with internal default of 1, will control if DA sends an HUP signal to the pid file set in the directadmin.conf setting: apache_pid=/var/run/httpd.pid or if nginx=1, DA internally sets it to: apache_pid=/var/run/nginx.pid via the nginx_pid variable. DA will read that value, and send a root call to: kill(pid, SIGHUP); If you do not wish to have the post-rotation send the HUP, you can set: reload_apache_after_rotation=0 in your directadmin.conf, and the HUP won't be sent. *** HOWEVER *** the HUP is sent for a reason. This is used to re-open all rotated logs and bytes logs. So if apache/nginx does not get the HUP, you may have logging issues. If needed, immediately after that HUP is sent, the hook script: tally_rotation_post.sh is called if it exists. So if you disable the HUP, you can take any other desired actions with that script.

Interested to try DirectAdmin? Get a 30-day Free Trial!