Levelrail
Skip to content

Self-host Moodle with Docker ​

A widely used, highly customizable learning management system for online courses.

This page describes the Levelrail template for Moodle (Applications). It deploys the services below as one Docker Compose app on your own server.

Project site: https://moodle.org.

Recommended memory: about 1024 MiB.

Services, ports and volumes ​

ServiceImageContainer portsVolumes
mariadbmariadb:11.1none
moodle_mariadb_data -> /var/lib/mysql
moodledocker.io/bitnamilegacy/moodle:4.38080
moodle_data -> /bitnami/moodle
moodledata_data -> /bitnami/moodledata

Environment variables ​

ServiceVariableValue
mariadbMYSQL_DATABASEPreset in the template
mariadbMYSQL_PASSWORDGenerated at deploy
mariadbMYSQL_ROOT_PASSWORDGenerated at deploy
mariadbMYSQL_USERPreset in the template
moodleALLOW_EMPTY_PASSWORDPreset in the template
moodleMOODLE_DATABASE_HOSTPreset in the template
moodleMOODLE_DATABASE_NAMEPreset in the template
moodleMOODLE_DATABASE_PASSWORDGenerated at deploy
moodleMOODLE_DATABASE_PORT_NUMBERPreset in the template
moodleMOODLE_DATABASE_USERPreset in the template
moodleMOODLE_EMAILPreset in the template
moodleMOODLE_PASSWORDGenerated at deploy
moodleMOODLE_SITE_NAMEPreset in the template
moodleMOODLE_USERNAMEPreset in the template

Passwords and keys marked as generated are created for you when the app is deployed and stored as secrets. Values are not shown here.

Deploy Moodle with Levelrail ​

In the dashboard, open Apps, choose New app, then Browse templates, and select Moodle. Review the Compose body and deploy.

With the CLI:

levelrail-cli templates deploy moodle --name my-moodle

See Service template catalog for how templates work, and Getting started if you have not installed Levelrail yet.

More Applications templates ​

All templates are listed in the self-host gallery.

Released under the Apache 2.0 License.