Process NMS-job immediatly
Posted: Sun Sep 09, 2012 1:35 pm
I've installed NMS 2.5.6 and CGJobMgr 1.2.7 and setup a cronjob every hour, just like Callguys example:
Everythings works great, scheduled jobs were processed fine by the cronjob.
But sometimes, for testing a newsletter, I want to process the job immediately. So I made a simple UDT to process the scheduled job:
This works fine when I execute this UDT in the admin-section, job is processed and nemwletter(s) were sent, but when I add this UDT to the JobCreated-event of CGJobMgr, both CGJobMgr and NMS give an error:
I can't figure out why this doesn't work.
Can anyone help me on this?
Code: Select all
0 * * * * wget -O /dev/null http://mysite.com/CGJobMgr/process >/dev/null 2>&1
But sometimes, for testing a newsletter, I want to process the job immediately. So I made a simple UDT to process the scheduled job:
Code: Select all
$cmd = "wget -O /dev/null http://www.mysite.com/CGJobMgr/process >/dev/null 2>&1";
exec($cmd);
I've tried cURL and file_get_contents() for the job-execution, but the same results.CGJobMGR: ERROR: setup failed
NMS: nms job has invalid status
I can't figure out why this doesn't work.
Can anyone help me on this?