Search code examples
phpcronapple-push-notificationsjobs

How to configure a cron job for EasyAPNS on a web server?


how do I have to configure a cron job for EasyAPNS on a real web server?

I have the following file (cronjob.phpx):

<?php
    exec("* * * * * nice /usr/bin/php -f http://mydomain.com/apns.php fetch > http://mydomain.com/apns.log 2>&1");
?>

But it doesn't work.

Thank's for any help.

Arno


Solution

  • My solution:

    1. I created a cron job file:

    cronjob.phpx

    1. content of the cron job file:

      include("http://mydomain.com/apns/apns.php");

    2. I created a cron job on the web server