Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@ This cronjob runs once every hours at the top of the hour, adding all users with
This offers us a way to keep class users added to course namespaces via ColdFront in sync with the in cluster OCP course group. To run this cronjob:

1. Ensure you are logged in to your OpenShift account via the CLI and you have access to rhods-notebooks namespace.
2. Switch to your course namespace:
2. Ensure that if multiple courses are running the groupsync cronjob, that the clusterrolebinding name in cronjobs/group-sync/clusterrolebinding.yaml is changed, as to not overwrite permissions for the cronjobs.
3. Switch to your course namespace:
```
oc project <namespace>
```

3. Update the `GROUP_NAME` and `NAMESPACE` env variables in cronjobs/group-sync/cronjob.yaml and update `namespace` variable in kustomization.yaml
4. From cronjobs/group-sync/ directory run:
4. Update the `GROUP_NAME` and `NAMESPACE` env variables in cronjobs/group-sync/cronjob.yaml and update `namespace` variable in kustomization.yaml
5. From cronjobs/group-sync/ directory run:
```
oc apply -k . --as system:admin
```
Expand Down
1 change: 1 addition & 0 deletions cronjobs/group-sync/clusterrolebinding.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
# CHANGE THIS VALUE TO BE RELEVANT TO CLASS NAME (if multiple classes are running group sync)
name: group-sync
subjects:
- kind: ServiceAccount
Expand Down