Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added the ability to use an existing/shared imge pull secret #1426

Merged
merged 1 commit into from
Oct 10, 2019
Merged
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
10 changes: 8 additions & 2 deletions jupyterhub/templates/hub/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,16 @@ spec:
{{- end }}
securityContext:
fsGroup: {{ .Values.hub.fsGid }}
{{- if .Values.hub.imagePullSecret.enabled }}
{{- if or .Values.hub.imagePullSecret.enabled .Values.hub.image.pullSecrets }}
imagePullSecrets:
{{- if .Values.hub.imagePullSecret.enabled }}
- name: hub-image-credentials
{{- end }}
{{ else }}
{{- range .Values.hub.image.pullSecrets }}
- name: {{ . }}
{{- end }}
{{- end }}
{{- end }}
{{- if .Values.hub.initContainers }}
initContainers:
{{- .Values.hub.initContainers | toYaml | trimSuffix "\n" | nindent 8 }}
Expand Down
8 changes: 7 additions & 1 deletion jupyterhub/templates/image-puller/_daemonset-helper.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,15 @@ spec:
{{- end }}
terminationGracePeriodSeconds: 0
automountServiceAccountToken: false
{{- if .Values.singleuser.imagePullSecret.enabled }}
{{- if or .Values.singleuser.imagePullSecret.enabled .Values.singleuser.image.pullSecrets }}
imagePullSecrets:
{{- if .Values.singleuser.imagePullSecret.enabled }}
- name: {{ if .hook -}} hook- {{- end -}} singleuser-image-credentials
{{ else }}
{{- range .Values.singleuser.image.pullSecrets }}
- name: {{ . }}
{{- end }}
{{ end }}
{{- end }}
initContainers:
- name: image-pull-singleuser
Expand Down
4 changes: 4 additions & 0 deletions jupyterhub/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ hub:
image:
name: jupyterhub/k8s-hub
tag: generated-by-chartpress
# pullSecrets:
# - secretName
resources:
requests:
cpu: 200m
Expand Down Expand Up @@ -245,6 +247,8 @@ singleuser:
name: jupyterhub/k8s-singleuser-sample
tag: generated-by-chartpress
pullPolicy: IfNotPresent
# pullSecrets:
# - secretName
imagePullSecret:
enabled: false
registry:
Expand Down