Derek Coleman & Associates Inc logoDerek Coleman & Associates Inc

Home / Support / Moodle on Ubuntu 24.04 LTS

Moodle on Ubuntu 24.04 LTS — Support & Quick Start

Moodle on Ubuntu 24.04 LTS — Moodle is the world's most widely used open-source learning management system for online courses, assessments, and training. Published by Derek Coleman & Associates Inc on the Azure Marketplace, deployed in your own Azure subscription.

Known issue on the current image (as of 2026-09-17)

The site installs and the generated admin sign-in works, but the image ships without Moodle's scheduled-task runner and with nothing listening on 443: no cron entry, cron.d file or timer ever runs admin/cli/cron.php, so scheduled tasks, outgoing mail, automated backups and search indexing never run and Site administration > Notifications flags the site as incomplete; and although the listing advertises ports 80 and 443, only 80 answers. (image build tested: 2026.916.1326)

What you will see: Site administration > Notifications shows the 'cron has not run' warning and it never clears; `systemctl list-timers` and `sudo crontab -l -u www-data` show nothing for Moodle; https://<VM-IP>/ is refused while http://<VM-IP>/ works.

Workaround:

  1. Add the runner yourself until the fixed image is published: `sudo crontab -u www-data -e` and append `* * * * * /usr/bin/php /var/www/html/moodle/admin/cli/cron.php >/dev/null 2>&1` (Moodle's documented cron line); the Notifications warning clears after the first run.
  2. For HTTPS, put a TLS certificate on Apache yourself (a self-signed one or Let's Encrypt via certbot) and change $CFG->wwwroot in /var/www/html/moodle/config.php to the https:// address — Moodle builds every link from wwwroot, so a TLS vhost beside an http:// wwwroot only produces mixed content.
( sudo crontab -l -u www-data 2>/dev/null; echo '* * * * * /usr/bin/php /var/www/html/moodle/admin/cli/cron.php >/dev/null 2>&1' ) | sudo crontab -u www-data -

Fix status: Fix in progress: image-factory PR #302 (open; build 2026.917.1837 running 2026-09-17) adds a moodle-cron systemd timer, a per-VM self-signed certificate with an https:// wwwroot and an 80→443 redirect, and makes first boot fail closed unless cron has actually run. Until that build is the published version, the image you deploy today is the one described above; the two steps above are the cure on it. Track the fix.

Source: our 2026-09-17 image sweep of the newest published build. This notice is removed when a build that passes the same test is live on the Marketplace.

Fixed on image version 2026.916.1326 (published 2026-09-17)

First boot now installs the site with an admin address Moodle's CLI installer accepts, runs the installer with the CLI php.ini, sets $CFG->wwwroot to the VM's public address and proves a real admin sign-in against the running site before it writes /var/moodledata/admin-password. http://<VM-IP>/login/index.php shows the Moodle login and the credential file is present (image-verify leg on this exact version: login proven).

If you deployed this VM before 2026-09-17, it came from the older image and is not changed by the new publication — redeploy from the current Marketplace version, or apply the one-time repair below:

  1. On a VM from an earlier image the installer never ran: there is no site, no admin user and no credential file. There is nothing on that VM to repair short of running Moodle's web installer yourself at http://<VM-IP>/ (it is unclaimed, so the first visitor becomes the admin — keep the NSG scoped to your own IP until you have). Redeploying from the current Marketplace version is the supported path; email support if you need help.

Image change: see the pull request.

Source: the Marketplace live version set for this offer, read from Partner Center on 2026-09-17. New deployments take the newest version by default.

At a glance

Application ports80 (web UI), 443
Open in browserhttp://<VM-IP>/login/index.php
Admin credential filesudo cat /var/moodledata/admin-password
Sign in asadmin
Service(s)apache2, postgresql
Configuration/var/www/moodle/config.php; data in /var/moodledata/
Logs/var/log/apache2/moodle_error.log
VersionMoodle 4.5.1 (Apache 2.4, PHP 8.3, PostgreSQL)
PlatformUbuntu 24.04 LTS

Quick start

  1. Deploy from the Azure Marketplace (Get It Now → Create), choosing your SSH key at the Administration step.
  2. Allow inbound SSH (22) for yourself plus the application port(s): 80 (web UI) — restrict to your own IP where possible. The in-image firewall already allows them; only the Network Security Group (NSG) keeps them closed.
  3. Open http://<VM-IP>/login/index.php and sign in as admin (see First login below).
  4. Set the site name and $CFG->wwwroot for your domain in /var/www/moodle/config.php, then enable HTTPS.

First login / credentials

This image generates its admin credential on the VM at first boot — nothing is pre-set. SSH into the VM with the username + key you chose at deploy, then print the generated credential:

ssh <your-username>@<VM-IP>
sudo cat /var/moodledata/admin-password

Sign in as admin.

  1. Print the credential file: MOODLE_ADMIN_USER=admin and MOODLE_ADMIN_PASSWORD (the database credentials are in the same file).
  2. Open http://<VM-IP>/login/index.php and sign in as admin.
  3. Change the password (Preferences → Change password) and delete the file. Self-registration is disabled by default.

Sign in as admin (unless noted), then change the password immediately. The file is root-only and can be deleted once the password is stored securely.

Still stuck?

Email support@dcassociatesgroup.com (response within 1 business day) or send a message via the contact form. Include the offer name, VM size, region, and any log output — sudo journalctl -u <service> -n 100 usually tells the story.