MESSENGERV3 will not work on Debian/Ubuntu
Posted: 13 Apr 2021, 14:27
In my testing I wasn't able to get the MESSENGERV3 to work correctly on Debian/Ubuntu servers (It can't find the SSL certificates). It looks like there is a bug in the Messenger.pm conftree function because it can't process the relative includes used by default on Debian/Ubuntu.
The config used in /etc/csf/csf.conf:
After restarting LFD
The problem is because on Debian/Ubuntu the default includes in /etc/apache2/apache2.conf are relative:
Changing the IncludeOptional lines in /etc/apache2/apache2.conf to the full path fixes the issue and all the SSL certificates are found properly like on Centos/RHEL/Cloudlinux. I think the simplest fix would just to alter the conftree function to detect if the include line starts with a leading slash and if not just prefix them off the /etc/apache2/ directory.
The config used in /etc/csf/csf.conf:
Code: Select all
MESSENGERV3 = "1"
MESSENGERV3LOCATION = "/etc/apache2/conf-enabled/"
MESSENGERV3RESTART = "systemctl restart apache2"
MESSENGERV3TEST = "/usr/sbin/apachectl -t"
MESSENGERV3HTTPS_CONF = "/etc/apache2/apache2.conf"
MESSENGERV3WEBSERVER = "apache"
MESSENGERV3PERMS = "711"
MESSENGERV3GROUP = "www-data"
Code: Select all
Apr 13 05:38:27 tpl_ubuntu18 lfd[59258]: Messenger HTTPS Service starting...
Apr 13 05:38:27 tpl_ubuntu18 lfd[59258]: Messenger HTML Service starting...
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: Processing [/etc/apache2/apache2.conf]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: IncludeOptional [/mods-enabled/*.load]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: IncludeOptional [/mods-enabled/*.conf]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: Including [/ports.conf]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: IncludeOptional [/conf-enabled/*.conf]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: SSL: IncludeOptional [/sites-enabled/*.conf]
Apr 13 05:38:27 tpl_ubuntu18 lfd[59269]: *MESSENGERV3* Error: No SSL domains found in MESSENGERV3HTTPS_CONF location [/etc/apache2/apache2.conf] for apache web server
Code: Select all
# Include generic snippets of statements
IncludeOptional conf-enabled/*.conf
# Include the virtual host configurations:
IncludeOptional sites-enabled/*.conf