Skip to content

Commit a823c62

Browse files
committed
Update README.md to include instructions for running ope-notebook-culler
1 parent ddd0670 commit a823c62

File tree

1 file changed

+37
-1
lines changed

1 file changed

+37
-1
lines changed

README.md

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,43 @@
22

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

5-
## get_url.py
5+
## Cronjobs
6+
7+
### ope-notebook-culler
8+
9+
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:
10+
11+
1. Ensure you are logged in to your OpenShift account via the CLI and you have access to rhods-notebooks namespace.
12+
2. Switch to rhods-notebooks namespace:
13+
```
14+
oc project rhods-notebooks
15+
```
16+
17+
3. From cronjobs/ope-notebook-culler/ directory run:
18+
```
19+
oc apply -k .
20+
```
21+
22+
This will deploy all the necessary resources for the cronjob to run on the specified schedule.
23+
24+
Alternatively, to run the script immediately:
25+
26+
1. Ensure you followed the steps above
27+
2. Verify the cronjob ope-notebook-culler exists
28+
```
29+
oc get cronjob ope-notebook-culler
30+
```
31+
32+
3. Run:
33+
```
34+
kubectl create -n rhods-notebooks job --from=cronjob/ope-notebook-culler ope-notebook-culler
35+
```
36+
37+
This will trigger the cronjob to spawn a job manually.
38+
39+
## Scripts
40+
41+
### get_url.py
642

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

0 commit comments

Comments
 (0)