Skip to content

This is an experimental Tutor plugin. You should not consider it ready for production use at this point.

License

Notifications You must be signed in to change notification settings

fccn/tutor-contrib-retirement

 
 

Repository files navigation

User Retirement Tutor plugin

This is an experimental plugin for Tutor that enables the user retirement feature in Open edX.

Version compatibility matrix

 You must install a supported release of this plugin to match the Open edX and Tutor version you are deploying. If you are installing this plugin from a branch in this Git repository, you must select the appropriate one:

Open edX release Tutor version Plugin branch Plugin release
Lilac >=12.0, <13 Not supported Not supported
Maple >=13.2, <141 maple 0.1.x
Nutmeg >=14.0, <15 nutmeg 1.x.x
Olive >=15.0, <16 quince 2.x.x
Palm >=16.0, <17 quince 3.x.x
Quince >=17.0, <18 quince 3.x.x
Redwood >=18.0, <19 main 5.x.x

Limitations

This plugin cannot be used for retiring accounts in the Open edX E-Commerce Service,2 nor the Course Discovery Service.3.

Installation

pip install git+https://github.com/hastexo/[email protected]

Usage

To enable this plugin, run:

tutor plugins enable retirement

Before starting Tutor, build the docker image:

tutor images build retirement

After enabling this plugin, you need to restart your Tutor deployment with tutor local quickstart or tutor k8s quickstart. This ensures that the retirement service worker is registered as an OAuth2 client in LMS and that the retirement pipeline stages are correctly populated in LMS.

To run the retirement pipeline in the Tutor local deployment:

tutor local retire-users

This will start the retirement-job service and run the retirement pipeline as described here. If you want to run this command periodically in a local deployment, you can invoke this command from a cron job on your host.

For a Kubernetes deployment, this plugin defines a CronJob which runs the retirement pipeline according to the schedule defined in the RETIREMENT_K8S_CRONJOB_SCHEDULE configuration parameter. You can also tweak the history limits for the CronJob.

Configuration

  • RETIREMENT_EDX_OAUTH2_CLIENT_ID (default "retirement_service_worker")
  • RETIREMENT_COOL_OFF_DAYS (default 30)
  • RETIREMENT_K8S_CRONJOB_HISTORYLIMIT_FAILURE (default 1)
  • RETIREMENT_K8S_CRONJOB_HISTORYLIMIT_SUCCESS (default 3)
  • RETIREMENT_K8S_CRONJOB_SCHEDULE (default "0 0 * * *", once a day at midnight)

These values can be modified with tutor config save --set PARAM_NAME=VALUE commands.

Footnotes

  1. For Open edX Maple and Tutor 13, you must run version 13.2.0 or  later. That is because this plugin uses the Tutor v1 plugin API,  which was introduced with that  release.

  2. See Issue #36 for background.

  3. See Issue #39 for background.

About

This is an experimental Tutor plugin. You should not consider it ready for production use at this point.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 80.2%
  • Shell 11.6%
  • Dockerfile 8.2%