Skip to content

Commit 7bcfa9d

Browse files
committed
Update README.md to include instructions for running ope-notebook-culler
1 parent b3d1563 commit 7bcfa9d

File tree

1 file changed

+33
-1
lines changed

1 file changed

+33
-1
lines changed

README.md

+33-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,39 @@
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+
3. From cronjobs/ope-notebook-culler/ directory run:
17+
```
18+
oc apply -k .
19+
```
20+
This will deploy all the necessary resources for the cronjob to run on the specified schedule.
21+
22+
Alternatively, to run the script immediately:
23+
24+
1. Ensure you followed the steps above
25+
2. Verify the cronjob ope-notebook-culler exists
26+
```
27+
oc get cronjob ope-notebook-culler
28+
```
29+
3. Run:
30+
```
31+
kubectl create -n rhods-notebooks job --from=cronjob/ope-notebook-culler ope-notebook-culler
32+
```
33+
This will trigger the cronjob to spawn a job manually.
34+
35+
## Scripts
36+
37+
### get_url.py
638

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

0 commit comments

Comments
 (0)