Skip to content

Commit 06139f0

Browse files
committed
helm-chart: Rely on z2jh to seed hub.services.binder.apiToken
1 parent f23e784 commit 06139f0

File tree

5 files changed

+4
-13
lines changed

5 files changed

+4
-13
lines changed

helm-chart/binderhub/templates/deployment.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ spec:
9898
- name: JUPYTERHUB_API_TOKEN
9999
valueFrom:
100100
secretKeyRef:
101-
name: binder-secret
102-
key: "binder.hub-token"
101+
name: "{{ include "jupyterhub.hub.fullname" . }}"
102+
key: hub.services.binder.apiToken
103103
{{- if .Values.config.BinderHub.auth_enabled }}
104104
- name: JUPYTERHUB_API_URL
105105
value: {{ (print (.Values.config.BinderHub.hub_url_local | default .Values.config.BinderHub.hub_url | trimSuffix "/") "/hub/api/") }}

helm-chart/binderhub/templates/secret.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ type: Opaque
66
data:
77
{{- $values := dict "config" dict }}
88
{{- $cfg := .Values.config }}
9-
binder.hub-token: {{ .Values.jupyterhub.hub.services.binder.apiToken | required "jupyterhub.hub.services.binder.apiToken must be explicitly set!" | b64enc | quote }}
109
{{- /* every 'pick' here should be matched with a corresponding 'omit' in secret.yaml */ -}}
1110
{{- if $cfg.GitHubRepoProvider }}
1211
{{- $_ := set $values.config "GitHubRepoProvider" (pick $cfg.GitHubRepoProvider "client_id" "client_secret" "access_token") }}

testing/k8s-binder-k8s-hub/binderhub-chart-config.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,10 @@ jupyterhub:
2828
allowOrigin: "*"
2929

3030
hub:
31-
# cookieSecret must be a hex encoded even length string
32-
cookieSecret: "cccccccccc"
3331
db:
3432
type: "sqlite-memory"
35-
services:
36-
binder:
37-
apiToken: "dummy-binder-secret-token"
3833

3934
proxy:
40-
secretToken: "dummy-proxy-secret-token"
4135
service:
4236
type: NodePort
4337
nodePorts:

testing/local-binder-k8s-hub/jupyterhub-chart-config.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,15 @@ custom:
1212
allowOrigin: "*"
1313

1414
hub:
15-
# cookieSecret must be a hex encoded even length string
16-
cookieSecret: "cccccccccc"
1715
db:
1816
type: "sqlite-memory"
1917
services:
2018
binder:
19+
# apiToken is also configured in
20+
# testing/local-binder-k8s-hub/binderhub_config.py
2121
apiToken: "dummy-binder-secret-token"
2222

2323
proxy:
24-
secretToken: "dummy-proxy-secret-token"
2524
service:
2625
type: NodePort
2726
nodePorts:

tools/templates/lint-and-validate-values.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ jupyterhub:
7070
services:
7171
binder:
7272
admin: true
73-
apiToken: dummy-binder-secret-token
7473
singleuser:
7574
cmd: jupyter-notebook
7675
events: false

0 commit comments

Comments
 (0)