Dockerized canvas to be used as a development environment.
We use ansible to setup the local development environment. You can install it using the package manager available on your OS. We use Ubuntu in the example here.
apt-get install ansible
We build the docker image which will serve as the development environment for us.
./build-docker-image.sh
We need to configure the environment before setting it up. We do this by modifying the environment parameters in ansible/playbooks/canvas/group_vars/all
.
Parameter | Description |
---|---|
canvas_src | The location of the canvas source code on your local machine |
canvas.admin_email | The canvas admin email address |
canvas.admin_password | The canvas admin password |
canvas.account_name | The canvas admin account name |
canvas.stats_collection | The canvas stats collection policy |
The ansible script creates a local canvas user on your machine.
It then creates a folder /etc/canvas
where we store all the configuration files related to canvas, apache and postgres. It also creates a symlink of the source code which points to the location provided by you in ansible/playbooks/canvas/group_vars/all
.
You must run the deploy-local.sh
script as sudo because it requires permissions to create the canvas user on your machine.
sudo ./deploy-local.sh
Once the deployment completes the canvas lms should be accessible on localhost
.