Skip to content

Commit f471952

Browse files
author
Michele
committed
Updated maintd cron entry
1 parent 303f7c4 commit f471952

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

install/lib/installer_base.lib.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -877,7 +877,8 @@ public function configure_mlmmj() {
877877
copy($conf['postfix']['config_dir'].'/master.cf', $conf['postfix']['config_dir'].'/master.cf~mlmmj');
878878
$content .= "\n# mlmmj mailing lists\n";
879879
$content .= "mlmmj unix - n n - - pipe\n";
880-
$content .= " flags=ORhu user=mlmmj argv=/usr/bin/mlmmj-receive -F -L /var/spool/mlmmj/\$nexthop\n\n";
880+
$content .= " flags=ORhu user=mlmmj argv=/usr/bin/mlmmj-receive -F -L /var/";
881+
$content .= $mlConfig['spool_dir']."/\$nexthop\n\n";
881882
wf($conf['postfix']['config_dir'].'/master.cf', $content);
882883
}
883884

@@ -888,6 +889,10 @@ public function configure_mlmmj() {
888889
exec("nohup /usr/sbin/postmap $configDir/virtual >/dev/null 2>&1");
889890
touch("$configDir/transport");
890891
exec("nohup /usr/sbin/postmap $configDir/transport >/dev/null 2>&1");
892+
893+
//* Create/update cron entry
894+
$cronEntry = 'find /var/'.$mlConfig['spool_dir'].'/ -mindepth 1 -maxdepth 1 -type d -exec /usr/bin/mlmmj-maintd -F -d {} \;'
895+
file_put_contents('/etc/cron.d/mlmmj', $cronEntry);
891896
}
892897

893898
public function get_postfix_service($service, $type) {

0 commit comments

Comments
 (0)