https://github.com/openfun/learning-analytics-playground
:factory: A playground using OpenEdx to generate factice learning logs
https://github.com/openfun/learning-analytics-playground
Last synced: about 1 year ago
JSON representation
:factory: A playground using OpenEdx to generate factice learning logs
- Host: GitHub
- URL: https://github.com/openfun/learning-analytics-playground
- Owner: openfun
- License: mit
- Created: 2021-05-04T14:12:43.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2024-08-23T13:58:38.000Z (over 1 year ago)
- Last Synced: 2025-03-24T00:14:09.918Z (about 1 year ago)
- Language: Python
- Homepage:
- Size: 209 KB
- Stars: 4
- Watchers: 9
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Learning analytics playground
## Description
This tool is dedicated to generate learning events (_aka_ tracking logs) from a LMS platform to
feed dashboard development testing datasets. It is intended to be used locally.
## Usage
### Launch Edx platform
1. Run the following command to launch the Edx platform:
```
make bootstrap
make run-edx
```
> Note: as the command includes migrations, it may take some time to complete (several minutes).
> Go grab a coffee, a tea or whatever pleases you!
2. When connections are established, you can access to:
- the LMS server on [localhost:8072](http://localhost:8072)
- the CMS server on [localhost:8082](http://localhost:8082)
- the Graylog server on [localhost:9000](http://localhost:9000)
3. Two users are available for testing the LMS/CMS:
| Role | Email | Password |
| ------- | ---------------- | -------- |
| admin | admin@example.com | admin |
| student | edx@example.com | edx |
> Note that it is also possible to create customized users at your convenience,
> but remember that those accounts will not persist if you remove the database container.
### Run end-to-end tests
In this playground, end-to-end tests have been implemented to simulate learning events generation.
As this project is evolving, the tests will progressively comprises a wide panel of use cases.
The following command runs end-to-end tests:
```
make test
```
## Graylog
Generated events with end-to-end tests or with manual navigation on the LMS service are observable on the Graylog server.
### Configure an input on Graylog interface
1. Access Graylog interface with `admin`:`admin` credentials.
2. To configure the input where to listen the LMS server, click on `System` bar menu and `Inputs`
button.
3. On Select input, choose `GELF TCP` and click on Launch new input button.
4. In the input window appearing, enter the input title you want.
5. Check that binding adress is `0.0.0.0` and the listening port is 12201.
6. Ensure that `Null frame delimiter?` option is activated (on the bottom of the windows),
otherwise logs won't be recognized and streamed.
7. Click on Save button.
### Stream events
1. Go on LMS server and navigate through the website.
2. On the Graylog server, go on `Search` and update the timeframe on `Search in all messages`
option if no logs are visible.
3. You should see appearing a list of all the messages you have generated!
## Keycloak
The keycloak SSO service is pre-configured for the `fun-mooc` realm.
Use the _ad hoc_ Make target to run the service:
```
make run-keycloak
```
It can be accessed at `http://localhost:8080`.
Admin credentials are: `admin:pass`.
The `potsie` client has been configured to login to `grafana` (see
the [openfun/potsie](https://github.com/openfun/potsie) project).
Use the _ad hoc_ Make target to provision `fun-mooc` realm:
```
make realm
```
You can now login to grafana using the following credentials:
`grafana:funfunfun`.
## License
This work is released under the MIT license (see [LICENSE](./LICENSE)).