Skip to content

Commit 45e6fbd

Browse files
committed
Ensure hub container is first by appending instead of prepending hub.extraContainers
By doing this, you'd be able to do `kubectl logs deploy/hub` and get the hub containers logs no matter what. Before, you'd get the first listed `hub.extraContainer` instead and have to add `--container=hub` to ensure getting the hub containers logs. I'm maintaining a deployment where we use hub.extraContainers, and by doing so, have been required to specify `-c hub` anytime I want logs, because its not the first container in the pod specs list of containers.
1 parent 470a027 commit 45e6fbd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

jupyterhub/templates/hub/deployment.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,9 +93,6 @@ spec:
9393
{{- . | toYaml | nindent 8 }}
9494
{{- end }}
9595
containers:
96-
{{- with .Values.hub.extraContainers }}
97-
{{- . | toYaml | nindent 8 }}
98-
{{- end }}
9996
- name: hub
10097
image: {{ .Values.hub.image.name }}:{{ .Values.hub.image.tag }}
10198
{{- with .Values.hub.command }}
@@ -238,6 +235,9 @@ spec:
238235
path: {{ .Values.hub.baseUrl | trimSuffix "/" }}/hub/health
239236
port: http
240237
{{- end }}
238+
{{- with .Values.hub.extraContainers }}
239+
{{- . | toYaml | nindent 8 }}
240+
{{- end }}
241241
{{- with .Values.hub.extraPodSpec }}
242242
{{- . | toYaml | nindent 6 }}
243243
{{- end }}

0 commit comments

Comments
 (0)