Contents

Chapter 2. Installation, Updates, and Support

Setting Up the Scheduled Tasks

PaddleSubs does its background work as Joomla scheduled tasks. Joomla doesn't create tasks for you: you add each one once, and choose how often it runs.

Procedure 2.6. Add the PaddleSubs tasks
  1. Go to System → Scheduled Tasks and click New.

  2. Choose the task type, give the task a name, set its schedule on the Execution Rules tab, and click Save & Close. Repeat for each task in the table.

Task typeWhat it doesSuggested schedule
PaddleSubs - Process webhooksWorks through the webhooks Paddle sent. Until it runs, nothing a customer bought reaches their account.Every minute
PaddleSubs - Access subscription lifecycleStarts and ends Access Subscriptions on time, adding and removing user groups.Every 5 to 15 minutes
PaddleSubs - Expiry remindersEmails customers before and after one-time access runs out.Once a day
PaddleSubs - Resync user groupsGives users the groups their purchases grant, after you change a product's or level's groups or after an import.Hourly, or by hand when you need it

Run the Scheduler From Your Server

By default, Joomla runs due tasks when someone visits your site. On a busy site that is often enough. On a quiet one, a customer can pay and then wait until the next visitor for their access. Set up a CRON job on your server that runs Joomla's scheduler every minute:

* * * * * php /path/to/your/site/cli/joomla.php scheduler:run --all --quiet

Your hosting control panel usually has a page for CRON jobs. Once it is set up, you can turn off Lazy Scheduler in the Scheduled Tasks options, so visitors never wait for a task to run.

Emails the tasks send link to your site. PaddleSubs builds those links from the Site Address option, which it fills in the first time an administrator opens one of its pages, or from $live_site in configuration.php when that is set. Open a PaddleSubs page once after installing, and check the option.