computer-playbook/roles/docker-moodle/templates/docker-compose.yml.j2

34 lines
1.1 KiB
Django/Jinja

services:
{% include 'templates/docker/services/' + database_type + '.yml.j2' %}
moodle:
image: docker.io/bitnami/moodle:latest
ports:
- 127.0.0.1:{{http_port}}:80
environment:
- MOODLE_DATABASE_HOST={{database_host}}
- MOODLE_DATABASE_PORT_NUMBER=3306
- MOODLE_DATABASE_USER={{database_username}}
- MOODLE_DATABASE_NAME={{database_name}}
- MOODLE_DATABASE_PASSWORD={{database_password}}
- ALLOW_EMPTY_PASSWORD=no
- MOODLE_SITE_NAME="{{moodle_site_name}}"
- MOODLE_SSLPROXY=yes
- MOODLE_REVERSE_PROXY=yes
- MOODLE_USERNAME={{moodle_user_name}}
- MOODLE_PASSWORD={{moodle_user_password}}
- MOODLE_EMAIL={{moodle_user_email}}
- BITNAMI_DEBUG={% if mode_debug | bool %}true{% else %}false{% endif %}
volumes:
- 'moodle:/bitnami/moodle'
- 'data:/bitnami/moodledata'
{% include 'templates/docker/container/depends-on-just-database.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
{% include 'templates/docker/compose/volumes.yml.j2' %}
moodle:
data:
{% include 'templates/docker/compose/networks.yml.j2' %}