Skip to content

Commit

Permalink
added toleration support for iam operator jupyter (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
tyu0912 authored Aug 2, 2024
1 parent aff0d10 commit b57c076
Show file tree
Hide file tree
Showing 6 changed files with 57 additions and 0 deletions.
3 changes: 3 additions & 0 deletions charts/datalayer-iam/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
{{- with .Values.iam.affinity }}
affinity: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.iam.tolerations }}
tolerations: {{- toYaml . | nindent 8 }}
{{- end }}
imagePullSecrets:
- name: reg-creds
containers:
Expand Down
16 changes: 16 additions & 0 deletions charts/datalayer-iam/tests/deployment_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@ tests:
operator: In
values:
- "true"
- it: "test tolerations"
set:
iam.tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
asserts:
- isSubset:
path: spec.template.spec
content:
tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
- it: "test environment variables"
asserts:
- isSubset:
Expand Down
3 changes: 3 additions & 0 deletions charts/datalayer-jupyter/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
{{- with .Values.jupyter.affinity }}
affinity: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.jupyter.tolerations }}
tolerations: {{- toYaml . | nindent 8 }}
{{- end }}
imagePullSecrets:
- name: reg-creds
containers:
Expand Down
16 changes: 16 additions & 0 deletions charts/datalayer-jupyter/tests/deployment_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@ tests:
operator: In
values:
- "true"
- it: "test tolerations"
set:
jupyter.tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
asserts:
- isSubset:
path: spec.template.spec
content:
tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
- it: "test environment variables"
asserts:
- isSubset:
Expand Down
3 changes: 3 additions & 0 deletions charts/datalayer-operator/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
{{- with .Values.operator.affinity }}
affinity: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.operator.tolerations }}
tolerations: {{- toYaml . | nindent 8 }}
{{- end }}
imagePullSecrets:
- name: reg-creds
containers:
Expand Down
16 changes: 16 additions & 0 deletions charts/datalayer-operator/tests/deployment_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@ tests:
operator: In
values:
- "true"
- it: "test tolerations"
set:
operator.tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
asserts:
- isSubset:
path: spec.template.spec
content:
tolerations:
- key: "key1"
operator: "Equal"
value: "value1"
effect: "NoSchedule"
- it: "test environment variables"
asserts:
- isSubset:
Expand Down

0 comments on commit b57c076

Please sign in to comment.