Abedi Pele
Abedi Pele

Reputation: 45

Cron every minute to trigger url via CURL

I want to set a CRON task to trigger an URL every minutes (via CURL). That seems pretty simple, I searched and wrote this :

* * * * * curl -—silent "https://urltotrigger.com/page.php" >/dev/null 2>&1

I added that to the crontab -e and saved. But it seems that the url is not triggered.

Don't understand why, everything seems correct? Can you help me please? Thx.

Upvotes: 3

Views: 3685

Answers (1)

Runcy Oommen
Runcy Oommen

Reputation: 504

Your cron entry is wrong. If you need it to be run every 1 minute, it should be like this:

*/1 * * * * curl -—silent "https://urltotrigger.com/page.php" >/dev/null 2>&1

Upvotes: 5

Related Questions