File tree Expand file tree Collapse file tree 3 files changed +21
-1
lines changed Expand file tree Collapse file tree 3 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -457,13 +457,19 @@ properties:
457
457
imageCleaner :
458
458
type : object
459
459
additionalProperties : false
460
- required : [enabled]
460
+ required :
461
+ - enabled
461
462
properties :
462
463
enabled :
463
464
type : boolean
464
465
description : |
465
466
TODO
466
467
image : *image-spec
468
+ cordon :
469
+ type : boolean
470
+ description : |
471
+ Whether to cordon the node while cleaning its images.
472
+ Disable, e.g. for single-node clusters.
467
473
delay :
468
474
type : integer
469
475
description : |
@@ -480,6 +486,12 @@ properties:
480
486
type : integer
481
487
description : |
482
488
TODO
489
+ extraEnv :
490
+ type : [object, array]
491
+ additionalProperties : true
492
+ description : |
493
+ see binderhub.deployment.extraEnv
494
+
483
495
host :
484
496
type : object
485
497
additionalProperties : false
Original file line number Diff line number Diff line change @@ -49,10 +49,12 @@ spec:
49
49
- name : socket-{{ $builderName }}
50
50
mountPath : /var/run/docker.sock
51
51
env :
52
+ {{- if .Values.imageCleaner.cordon }}
52
53
- name : DOCKER_IMAGE_CLEANER_NODE_NAME
53
54
valueFrom :
54
55
fieldRef :
55
56
fieldPath : spec.nodeName
57
+ {{- end }}
56
58
- name : DOCKER_IMAGE_CLEANER_PATH_TO_CHECK
57
59
value : /var/lib/{{ $builderName }}
58
60
- name : DOCKER_IMAGE_CLEANER_DELAY_SECONDS
63
65
value : {{ .Values.imageCleaner.imageGCThresholdHigh | quote }}
64
66
- name : DOCKER_IMAGE_CLEANER_THRESHOLD_LOW
65
67
value : {{ .Values.imageCleaner.imageGCThresholdLow | quote }}
68
+ {{- with .Values.imageCleaner.extraEnv }}
69
+ {{- include "jupyterhub.extraEnv" . | nindent 8 }}
70
+ {{- end }}
66
71
terminationGracePeriodSeconds : 0
67
72
volumes :
68
73
{{- if eq $builderName "host" }}
Original file line number Diff line number Diff line change @@ -313,11 +313,14 @@ pink:
313
313
314
314
imageCleaner :
315
315
enabled : true
316
+ extraEnv : {}
316
317
image :
317
318
name : quay.io/jupyterhub/docker-image-cleaner
318
319
tag : " 1.0.0-beta.3"
319
320
pullPolicy : " "
320
321
pullSecrets : []
322
+ # whether to cordon nodes while cleaning
323
+ cordon : true
321
324
# delete an image at most every 5 seconds
322
325
delay : 5
323
326
# Interpret threshold values as percentage or bytes
You can’t perform that action at this time.
0 commit comments