Moodle: step 2. SSL certificate and cron

In the examples my-school.com is your site domain, myschool is the site user and 203.0.113.10 is the server address. Use your own values.

SSL certificate

The certificate is issued once the domain points to the server (DNS).

  1. Site → "SSL/TLS" tab → "Actions" → "New Let's Encrypt Certificate".
  2. Keep my-school.com and www.my-school.com. Click "Create and Install".
Issuing a Let's Encrypt certificate
Issuing a Let's Encrypt certificate

The site was installed with an https:// address, so nothing needs changing after the certificate is issued. It renews automatically.

Cron

Moodle runs background tasks every minute: notifications, grading, clean-up. Without cron some features do not work and the admin area shows a warning.

  1. Site → "Cron Jobs" tab → "Add Cron Job".
  2. Template: "Every Minute".
  3. Command:
/usr/bin/php8.4 /home/myschool/htdocs/my-school.com/admin/cli/cron.php >/dev/null
  1. Click "Add Cron Job".
New cron job for Moodle
New cron job for Moodle
The job is saved
The job is saved

The path to cron.php has no public: the file is in admin/cli of the Moodle root. The PHP version in the command must match the site.