File tree Expand file tree Collapse file tree 6 files changed +77
-0
lines changed Expand file tree Collapse file tree 6 files changed +77
-0
lines changed Original file line number Diff line number Diff line change 196196 { {- include " jupyterhub.fullname.dash" . } }hook-image-puller
197197{ {- end } }
198198
199+ { {- /* hook-image-puller ServiceAccount */} }
200+ { {- define " jupyterhub.hook-image-puller-serviceaccount.fullname" -} }
201+ { {- if .Values.prePuller.hook.serviceAccountImagePuller.create } }
202+ { {- .Values.prePuller.hook.serviceAccountImagePuller.name | default (include " jupyterhub.hook-image-puller.fullname" .) } }
203+ { {- else } }
204+ { {- .Values.prePuller.hook.serviceAccountImagePuller.name | default " default" } }
205+ { {- end } }
206+ { {- end } }
207+
199208{ {- /* continuous-image-puller DaemonSet */} }
200209{ {- define " jupyterhub.continuous-image-puller.fullname" -} }
201210 { {- include " jupyterhub.fullname.dash" . } }continuous-image-puller
202211{ {- end } }
203212
213+ { {- /* continuous-image-puller ServiceAccount */} }
214+ { {- define " jupyterhub.continuous-image-puller-serviceaccount.fullname" -} }
215+ { {- if .Values.prePuller.continuous.serviceAccount.create } }
216+ { {- .Values.prePuller.continuous.serviceAccount.name | default (include " jupyterhub.continuous-image-puller.fullname" .) } }
217+ { {- else } }
218+ { {- .Values.prePuller.continuous.serviceAccount.name | default " default" } }
219+ { {- end } }
220+ { {- end } }
221+
204222{ {- /* singleuser NetworkPolicy */} }
205223{ {- define " jupyterhub.singleuser.fullname" -} }
206224 { {- include " jupyterhub.fullname.dash" . } }singleuser
Original file line number Diff line number Diff line change 7070 { {- include " jupyterhub.userNodeAffinityRequired" . | nindent 14 } }
7171 { {- end } }
7272 terminationGracePeriodSeconds: 0
73+ { {- if .hook } }
74+ { {- with include " jupyterhub.hook-image-puller-serviceaccount.fullname" . } }
75+ serviceAccountName: { { . } }
76+ { {- end } }
77+ { {- else } }
78+ { {- with include " jupyterhub.continuous-image-puller-serviceaccount.fullname" . } }
79+ serviceAccountName: { { . } }
80+ { {- end } }
81+ { {- end } }
7382 automountServiceAccountToken: false
7483 { {- with include " jupyterhub.imagePullSecrets" (dict " root" . " image" .Values.singleuser.image) } }
7584 imagePullSecrets: { { . } }
Original file line number Diff line number Diff line change 1+ {{- /*
2+ ServiceAccount for the continuous image-puller daemonset
3+ */}}
4+ {{- if .Values.prePuller.continuous.serviceAccount.create -}}
5+ {{- if .Values.prePuller.continuous.enabled -}}
6+ apiVersion : v1
7+ kind : ServiceAccount
8+ metadata :
9+ name : {{ include "jupyterhub.continuous-image-puller.fullname" . }}
10+ labels :
11+ {{- include "jupyterhub.labels" . | nindent 4 }}
12+ annotations :
13+ {{- with .Values.prePuller.continuous.serviceAccount.annotations }}
14+ {{- . | toYaml | nindent 4 }}
15+ {{- end }}
16+ {{- end }}
17+ {{- end }}
Original file line number Diff line number Diff line change 1+ {{- /*
2+ ServiceAccount for the hook image-puller daemonset
3+ */}}
4+ {{- if .Values.prePuller.hook.serviceAccountImagePuller.create -}}
5+ {{- if (include "jupyterhub.imagePuller.daemonset.hook.install" .) -}}
6+ apiVersion : v1
7+ kind : ServiceAccount
8+ metadata :
9+ name : {{ include "jupyterhub.hook-image-puller-serviceaccount.fullname" . }}
10+ labels :
11+ {{- include "jupyterhub.labels" . | nindent 4 }}
12+ hub.jupyter.org/deletable : " true"
13+ annotations :
14+ " helm.sh/hook " : pre-install,pre-upgrade
15+ " helm.sh/hook-delete-policy " : before-hook-creation,hook-succeeded
16+ " helm.sh/hook-weight " : " 0"
17+ {{- with .Values.prePuller.hook.serviceAccountImagePuller.annotations }}
18+ {{- . | toYaml | nindent 4 }}
19+ {{- end }}
20+ {{- end }}
21+ {{- end }}
Original file line number Diff line number Diff line change @@ -2864,6 +2864,7 @@ properties:
28642864 image : *image-spec
28652865 resources : *resources-spec
28662866 serviceAccount : *serviceAccount
2867+ serviceAccountImagePuller : *serviceAccount
28672868 continuous :
28682869 type : object
28692870 additionalProperties : false
@@ -2880,6 +2881,7 @@ properties:
28802881 properties :
28812882 enabled :
28822883 type : boolean
2884+ serviceAccount : *serviceAccount
28832885 pullProfileListImages :
28842886 type : boolean
28852887 description : |
Original file line number Diff line number Diff line change @@ -665,12 +665,22 @@ prePuller:
665665 nodeSelector : {}
666666 tolerations : []
667667 resources : {}
668+ # Service Account for the hook-image-awaiter Job
668669 serviceAccount :
669670 create : true
670671 name :
671672 annotations : {}
673+ # Service Account for the hook-image-puller DaemonSet
674+ serviceAccountImagePuller :
675+ create : true
676+ name :
677+ annotations : {}
672678 continuous :
673679 enabled : true
680+ serviceAccount :
681+ create : true
682+ name :
683+ annotations : {}
674684 pullProfileListImages : true
675685 extraImages : {}
676686 pause :
You can’t perform that action at this time.
0 commit comments