6
0
mirror of https://github.com/ChristianLight/tutor.git synced 2024-11-10 15:20:56 +00:00
tutor/docker-compose.yml
Régis Behmo e357e763d7 Multiple improvements, including Ginkgo compatibility
Docker stack now includes a studio, smtp server, rabbitmq container and
an LMS worker. There are still a couple things to do, though. (see
TODOs)
2017-07-25 23:24:36 +02:00

93 lines
1.9 KiB
YAML

version: "3"
services:
############# External services
memcached:
image: memcached:1.4.38
mongodb:
# Use WiredTiger in all environments, just like at edx.org
command: mongod --smallfiles --nojournal --storageEngine wiredTiger
image: mongo:3.0.14
volumes:
- ./data/mongodb:/data/db
mysql:
image: mysql:5.6.36
command: mysqld --character-set-server=utf8 --collation-server=utf8_general_ci
environment:
MYSQL_ROOT_PASSWORD: ""
MYSQL_DATABASE: "openedx"
MYSQL_USER: "openedx"
MYSQL_PASSWORD: "password"
MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
volumes:
- ./data/mysql:/var/lib/mysql
nginx:
build: ./nginx
restart: on-failure
ports:
- "8800:80"
volumes:
- ./data/edxapp:/openedx/data:ro
depends_on:
- lms
rabbitmq:
image: rabbitmq:3.6.10
volumes:
- ./data/rabbitmq:/var/lib/rabbitmq
# Simple SMTP server
smtp:
image: namshi/smtp
environment:
PORT: 9025
############# LMS and CMS
lms:
build:
context: ./edxapp
args:
service_variant: lms
restart: on-failure
volumes:
- ./data/edxapp:/openedx/data
depends_on:
- memcached
- mongodb
- mysql
- rabbitmq
- smtp
cms:
build:
context: ./edxapp
args:
service_variant: cms
restart: on-failure
volumes:
- ./data/edxapp:/openedx/data
depends_on:
- lms
############# LMS and CMS workers
# TODO one service per queue?
lms_worker:
build:
context: ./edxapp
args:
service_variant: lms
command: ./manage.py lms --settings=production celery worker --loglevel=info --hostname=edx.lms.core.default.%%h --maxtasksperchild 100
environment:
C_FORCE_ROOT: "1" # run celery tasks as root #nofear
restart: on-failure
volumes:
- ./data/edxapp:/openedx/data
depends_on:
- lms