These instructions will get a copy of MyLA up and running on your local machine with anonymized/fake student data.
To follow the instructions below, you will at minimum need the following:
git clone https://github.com/tl-its-umich-edu/my-learning-analytics.git
cd my-learning-analytics
mylasecrets
. This directory is mapped by docker-compose.yml
into the container as /secrets/
.
mkdir ~/mylasecrets
config/env_sample.hjson
file into mylasecrets
as env.hjson
.
cp config/env_sample.hjson ~/mylasecrets/env.hjson
config/cron_udp.hjson
file into mylasecrets
. This step is Optional, since the MyLA cron query file path defaults to config/cron_udp.hjson
.
cp config/cron_udp.hjson ~/mylasecrets/cron_udp.hjson
Examine the env.hjson
file. You may need to change some of the configuration values for different environments,
e.g. localhost vs. a production deployment. There are comments to help determine the proper settings.
See Configuration for some additional info.
Note: You may also optionally place the JSON settings directly into the
ENV_JSON
environment variable if your deployment environment doesn’t easily support mounting theenv.hjson
file into container. When usingENV_JSON
, put the entire contents ofenv.hjson
into it as a single-line string.
.env.sample
file as .env
.
cp .env.sample .env
Examine the .env
file. It will have the suggested default environment variable settings,
mostly just MySQL information as well as locations of other configuration files.
docker compose build
docker compose up
Note: Use
docker compose down
and^C
at any time to stop the running containers.
Download the latest SQL file from this Google Drive link, and move it into the repository.
docker exec -i student_dashboard_mysql mysql \
-u student_dashboard_user \
--password=student_dashboard_pw student_dashboard \
< {name of sql file}
root
with password root
.As you are now logged in as root
, there are no courses listed.
To view a course and the visualizations as an admin, do the following:
Go to the Django admin panel by clicking the avatar in the top right, then clicking “Admin”, or navigate to http://localhost:5001/admin.
Click on “Courses” under “Dashboard” in the right-hand panel.
Click on one of the “Link” links in the “Course Link” column for one of the three courses.
If you are logged in as root
, click on the top-right circle, then click “Logout”.
Host: 127.0.0.1
Username: student_dashboard_user
Password: student_dashboard_pw
Database: student_dashboard
Port: 5306
sis_name
from the user
table to be used in the next step.
SELECT sis_name FROM `user` WHERE enrollment_type = 'StudentEnrollment';
docker exec -it student_dashboard python manage.py createuser \
--username={insert sis_name} \
--password={create password} \
--email=test@test.com
Note: To make a user a superuser, edit the record in
auth_user
to setis_staff=1
andis_superuser=1
.
Login using the username and password created.
sis_name
are enrolled in will be displayed.
Click on a course to view as the student selected in step 3.