A Moodle PHP environment configured for Moodle development based on Official PHP Images.
The following command will expose the current working directory on port 8080:
$ docker run --name web0 -p 8080:80 -v $PWD:/var/www/html moodlehq/moodle-php-apache:7.1
- Preconfigured with all php extensions required for Moodle development and all database drivers
- Serves wwroot configured at /var/www/html/
- For PHP 7.3 and up, both
linux/amd64
andlinux/arm64
images are being built. Note thatlinux/arm64
doesn't support the sqlsrv and oci extensions yet. Other than that, both architectures work exactly the same. - Verified by automated tests.
- Autobuilt from GHA, on push.
To faciliate testing and easy setup the following directories are created and owned by www-data by default:
/var/www/moodledata
/var/www/phpunitdata
/var/www/behatdata
/var/www/behatfaildumps
This container is part of a set of containers for Moodle development, see also:
- moodle-docker a docker-composer based set of tools to get Moodle development running with zero configuration
- moodle-db-mssql Microsoft SQL Server for Linux configured for Moodle development
- moodle-db-oracle Oracle XE configured for Moodle development