You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have the following being executed on a cron job every minute
$scheduler = new GO\Scheduler([
'email' => [
'subject' => 'Hourly Email History From Attendee Scheduler',
'from' => ADMIN_EMAIL,
'body' => 'This is the daily visitors count',
'transport' => $transport,
'ignore_empty_output' => true,
]
]);
$scheduler->call(
function($run, $per_minute, $trottle) use ($emailer, $logger) {
if($emailer->sendAttendeeEmails($run, $per_minute, $trottle) == -1)
{
trigger_error(sprintf('These emails failed to send %s' , join(',', $emailer->get_failed())), E_USER_WARNING);
}
echo "Total emails send {$emailer->get_sent()}";
echo "{$logger->dump()}";
},
[
$NUM_EMAIL_PER_RUN,
$EMAILS_PER_MINUTE,
$NUM_SECS_PAUSE_RUN
],
'SchedulerEmail'
)->at("*/2 * * * *")->output('run.log')->email([
[
'themegastore_admin@smsmail.net' => 'Admin Store'
],
'themegastore@smsmail.net'
]);
// Let the scheduler execute jobs which are due.
$scheduler->run();
The above code uses SwiftMailer to execute batch emails every 2 minutes then email and save to a file. While the job runs as expected I get neither an email nor an output file
I'm running PHP 7.0.32 using 2.*
Is it that I cannot run both or is there something else I'm missing here
UPDATE
I'm able now get the logs but not the emails
The text was updated successfully, but these errors were encountered:
I have the following being executed on a cron job every minute
The above code uses SwiftMailer to execute batch emails every 2 minutes then email and save to a file. While the job runs as expected I get neither an email nor an output file
I'm running PHP 7.0.32 using 2.*
Is it that I cannot run both or is there something else I'm missing here
UPDATE
I'm able now get the logs but not the emails
The text was updated successfully, but these errors were encountered: