Skip to content

How to setup scheduled cron on AWS Lightsail LAMP server

edited March 2020 in Contributions

First, just wanted to say awesome program!

Second, I had an issue getting the scheduled cron to work. The solution for me was to include the full bin path of php. So, to make it work,

  1. Log into your Lightsail server's console

  2. Type in

sudo crontab -e

  1. Paste the following at the bottom of the file:

*/5 * * * * /opt/bitnami/php/bin/php /opt/bitnami/apache2/htdocs/sendy/scheduled.php >> /dev/null 2>&1

Thirdly, code change recommendation to send-to.php ~line 841

<pre id="command"><?php echo PHP_BINARY;?> <?php echo $server_path;?>scheduled.php > /dev/null 2>&1</pre>

Although I haven't tested the PHP_BINARY constant extensively on shared servers.

Keep up the great work!

Comments

  • Thank you for sharing and glad to hear you like Sendy. :)

This discussion has been closed.