I need to call a Kohana helper (or any php MVC framework) from a Cron job.
How can I do this?
The server is Linux, so, I can only think of two possible solutions:
1- Open an URL from the cron job, which hits a controller and does what it has to do.
2- Call a Kohana controller without passing through the web server, but with the PHP CLI. (is that even possible? I don't think so, it might need the web server environment to work)
Know a solution? Thanks
with the kohana framework you can pass the "uri" as a command line parameter:
/path/to/index.php controller/method/param
you might want to try that, you will definitely need a controller but you dont need to use wget or curl
Can't you just curl or wget the URL?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With