Skip to content

Commit

Permalink
Update README.md to include instructions for running ope-notebook-culler
Browse files Browse the repository at this point in the history
  • Loading branch information
dystewart committed Jan 19, 2024
1 parent b3d1563 commit 7bcfa9d
Showing 1 changed file with 33 additions and 1 deletion.
34 changes: 33 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,39 @@

This repository is a collection of useful scripts and tools for TAs and professors to manage students workloads.

## get_url.py
## Cronjobs

### ope-notebook-culler

This cronjob runs once every 48 hours at 7am, removing all notebooks from the rhods-notebooks namespace. To add resources to the rhods-notebooks namespace:

1. Ensure you are logged in to your OpenShift account via the CLI and you have access to rhods-notebooks namespace.
2. Switch to rhods-notebooks namespace:
```
oc project rhods-notebooks
```
3. From cronjobs/ope-notebook-culler/ directory run:
```
oc apply -k .
```
This will deploy all the necessary resources for the cronjob to run on the specified schedule.

Alternatively, to run the script immediately:

1. Ensure you followed the steps above
2. Verify the cronjob ope-notebook-culler exists
```
oc get cronjob ope-notebook-culler
```
3. Run:
```
kubectl create -n rhods-notebooks job --from=cronjob/ope-notebook-culler ope-notebook-culler
```
This will trigger the cronjob to spawn a job manually.

## Scripts

### get_url.py

This script is used to retrieve the URL for a particular notebook associated with one student. To execute this script:

Expand Down

0 comments on commit 7bcfa9d

Please sign in to comment.