Skip to main content

Welcome to ipMoodle

ipMoodle is a production-ready Docker deployment solution for Moodle LMS. It provides a complete, optimized stack with PostgreSQL database, Nginx web server, and automated maintenance tasks — all orchestrated with Docker Compose.

Quickstart

Get Moodle running in minutes with our one-command deployment

Architecture

Understand the multi-container architecture and service design

Configuration

Customize environment variables, PHP settings, and Nginx configuration

Operations

Learn how to maintain, backup, and monitor your Moodle instance

Key Features

One-Command Deployment

Run deploy.sh to automatically build images, configure services, and download Moodle 4.3

Optimized PHP Runtime

PHP 8.2-FPM Alpine image with all required extensions: GD, Intl, SOAP, ZIP, PostgreSQL, Sodium, and more

PostgreSQL 16

Modern, reliable database with Alpine-based image for minimal footprint

Nginx FastCGI

High-performance web server configured for Moodle’s slash arguments and large file uploads (512MB)

Automated Cron Jobs

Dedicated cron container executes Moodle maintenance tasks every minute

Persistent Storage

Docker volumes for Moodle code, user uploads (moodledata), and database files

Architecture Overview

ipMoodle uses a four-container architecture:
All containers communicate over a dedicated moodle-net bridge network for isolation and security.

Service Breakdown

  • web (nginx:alpine) - Listens on port 80, serves static files, proxies PHP requests to app container
  • app (custom PHP 8.2-FPM) - Executes Moodle PHP code, connects to database
  • db (postgres:16-alpine) - Stores Moodle data with persistent volume
  • cron (custom PHP 8.2-FPM) - Runs scheduled tasks every minute for Moodle maintenance

What’s Included

1

Automated Deployment Script

deploy.sh handles environment setup, Docker builds, service startup, and Moodle download
2

Custom Docker Image

Optimized PHP 8.2-FPM with extensions: intl, soap, zip, pgsql, pdo_pgsql, exif, opcache, bcmath, sockets, mbstring, sodium, and gd
3

PHP Configuration

Pre-tuned for Moodle with 512MB memory limit, 512MB upload size, and 600s execution time
4

Nginx Configuration

FastCGI setup with slash arguments support, security hardening, and large request buffers

Environment Variables

The deployment is configured through four core environment variables:
VariableDescriptionDefault
SITE_URLPublic URL where Moodle will be accessible(required)
DB_NAMEPostgreSQL database namemoodle
DB_USERPostgreSQL usernamemoodle
DB_PASSPostgreSQL passwordmoodle
Change DB_PASS to a strong password before deploying to production.

Quick Example

Get started in three simple steps:
# 1. Set your site URL
export SITE_URL="http://localhost"

# 2. Run the deployment script
chmod +x deploy.sh
./deploy.sh

# 3. Access Moodle
open http://localhost
The deployment script downloads Moodle 4.3 (Latest Stable) automatically if the ./html directory is empty.

Next Steps

Start the Quickstart

Deploy your first Moodle instance in under 5 minutes

Explore Configuration

Learn how to customize PHP settings, database credentials, and more

Understand the Stack

Deep dive into each service and how they work together

Production Deployment

Configure SSL/HTTPS and security hardening for production use

Build docs developers (and LLMs) love