snipe-it icon indicating copy to clipboard operation
snipe-it copied to clipboard

Issues in setting cron job for license expiration alert

Open viewmithun opened this issue 10 years ago • 4 comments

Hi Snipe,

I am unable to set cron job for license expiration alert. What is the exact file, I should point in the Cron job? Could you please help me with that?

Thanks in advance.

Regards,

viewmithun avatar Jan 28 '16 11:01 viewmithun

It's not a file, it's a command. http://docs.snipeitapp.com/manual/alerts.html

snipe avatar Jan 28 '16 18:01 snipe

Hi Snipe,

Thank you so much for the link. YOU ROCK!

I tried implementing the Cron job and restarted the Cron service, but got the below error. Could you please let me know whether my configurations are correct,

snipe@snipe$ service cron restart stop: Rejected send message, 1 matched rules; type="method_call", sender=":1.163" (uid=1000 pid=11294 comm="stop cron ") interface="com.ubuntu.Upstart0_6.Job" member="Stop" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init") start: Rejected send message, 1 matched rules; type="method_call", sender=":1.164" (uid=1000 pid=11288 comm="start cron ") interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init")

My Crontab -l is,

59 * * * * /usr/bin/php /path/to/the/file/emails/expiring-assets-report.blade.php 59 * * * * /usr/bin/php /path/to/the/file/emails/expiring-licenses-report.blade.php

Appreciate your help very much, Snipe.

viewmithun avatar Jan 29 '16 09:01 viewmithun

Is this command right?

59 * * * * /usr/bin/php /path/to/the/file/start/artisan.php

viewmithun avatar Jan 29 '16 10:01 viewmithun

The link I gave you shows you what the cron should be pointing at. /path/to/php /path/to/your/snipe-it/artisan alerts:expiring. You have to replace /path/to/your/snipe-it with your actual path.

snipe avatar Jan 29 '16 17:01 snipe