...
- /home/user/a-plus/:/src/aplus/:ro
- /home/user/mooc-grader/:/src/grader/:ro
- The first path before the colon is the local path that you need to fix for your own computer.
- A-plus is installed in
/srv/aplus
in the run-aplus-front container. You can mount development version of the source code to/src/aplus
. The container will then copy it to/srv/aplus
and compile the translation file (django.mo). If you mount directly to/srv/aplus
, you need to manually compile the translation file beforehand, but on the other hand, Django can reload the code and restart the server without restarting the whole container when you edit the source code files. - The same applies to the run-mooc-grader container, but the paths inside the container are
/src/grader
and/srv/grader
. - In the run-mooc-grader container, the course directory should be mounted to
/srv/courses/default
. If you mount the mooc-grader code to/srv/grader
, then you need to change the course directory mount to/srv/grader/courses/default
- You should add the following symbolic link to the root of the mooc-grader directory in your computer:
ln -s /srv/courses/ exercises
- With the symbolic link, the run-mooc-grader container finds the course directory even when you mount your own mooc-grader source code into the container.
- The run-mooc-grader container normally mounts the course directory
/srv/courses/default
- In the run-mooc-grader container, if you do not use the symbolic link "exercises → /srv/courses" and if you mount the mooc-grader code to
/srv/grader
, then you need to change the course directory mount to/srv/grader/courses/default
in docker-compose.yml.
Code Block | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
version: '3' volumes: data: services: grader: image: apluslms/run-mooc-grader:1.8 volumes: - data:/data - /var/run/docker.sock:/var/run/docker.sock - /tmp/aplus:/tmp/aplus # This file should be in a course directory and # the course directory is mounted to the MOOC-Grader container. - .:/srv/courses/default:ro # mount the mooc-grader source code to one of the two options: - /home/user/mooc-grader:/src/grader:ro #- /home/user/mooc-grader:/srv/grader #- .:/srv/grader/courses/default:ro ports: - "8080:8080" plus: image: apluslms/run-aplus-front:1.8 volumes: - data:/data # mount the A+ source code to one of these: - /home/user/a-plus:/src/aplus:ro #- /home/user/a-plus:/srv/aplus:ro ports: - "8000:8000" depends_on: - grader |
...
Code Block | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
DEBUG = True BASE_URL = 'http://localhost:8000/' |
...