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

ci: update Core Operator chart #282

Merged
merged 1 commit into from
Nov 5, 2024
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
4 changes: 2 additions & 2 deletions charts/core-crd/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: core-crd
description: A Helm chart for Kubernetes
type: application
version: 3.5.0
appVersion: "v3.5.0"
version: 3.7.0
appVersion: "v3.7.0"
maintainers:
- name: Calyptia
email: [email protected]
Expand Down
2 changes: 1 addition & 1 deletion charts/core-crd/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ images:
fluentBit:
registry: ghcr.io
repository: calyptia/core/calyptia-fluent-bit
tag: 24.10.2
tag: 24.10.4
pullSecrets: []
ingestCheck:
registry: ghcr.io
Expand Down
4 changes: 2 additions & 2 deletions charts/core-instance/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ description: Calyptia Core Instance chart
home: https://calyptia.com/products/core/
icon: https://storage.googleapis.com/calyptia_public_resources_bucket/logo-darkmode.svg
type: application
version: 3.5.0
appVersion: "v3.5.0"
version: 3.7.0
appVersion: "v3.7.0"
maintainers:
- name: Calyptia
email: [email protected]
Expand Down
4 changes: 2 additions & 2 deletions charts/core-instance/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ images:
fromCloud:
registry: ghcr.io
repository: calyptia/core-operator/sync-from-cloud
tag: 3.5.0
tag: 3.7.0
pullSecrets: []
toCloud:
registry: ghcr.io
repository: calyptia/core-operator/sync-to-cloud
tag: 3.5.0
tag: 3.7.0
pullSecrets: []
hotReload:
registry: ghcr.io
Expand Down
4 changes: 2 additions & 2 deletions charts/core-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ description: Calyptia Core Operator chart
home: https://calyptia.com/products/core/
icon: https://storage.googleapis.com/calyptia_public_resources_bucket/logo-darkmode.svg
type: application
version: 3.5.0
appVersion: "v3.5.0"
version: 3.7.0
appVersion: "v3.7.0"
maintainers:
- name: Calyptia
email: [email protected]
Expand Down
15 changes: 15 additions & 0 deletions charts/core-operator/templates/manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,21 @@ spec:
serviceAccount: {{ template "operator.serviceAccountName" . }}
{{- include "operator.imagePullSecrets" . | nindent 6 }}
terminationGracePeriodSeconds: 10
{{- if .Values.calyptiaTolerations }}
tolerations:
{{- $tolerations := .Values.calyptiaTolerations | split "," }}
{{- range $toleration := $tolerations }}
{{- $tolerationParts := split ":" $toleration }}
{{- $keyValue := split "=" (index $tolerationParts._0) }}
- key: "{{ $keyValue._0 }}"
operator: "{{ $keyValue._1 }}"
value: "{{ index $tolerationParts._1 }}"
effect: "{{ index $tolerationParts._2 }}"
{{- if gt (len $tolerationParts) 3 }}
tolerationSeconds: {{ index $tolerationParts._3 }}
{{- end }}
{{- end }}
{{- end }}
volumes:
{{- if .Values.extraVolumes }}
{{- include "common.tplvalues.render" (dict "value" .Values.extraVolumes "context" $) | nindent 8 }}
Expand Down
63 changes: 63 additions & 0 deletions charts/core-operator/tests/manager_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,66 @@ tests:
- equal:
path: metadata.namespace
value: test
- it: checks tolerations key
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[0].key
value: "key1"
- it: checks tolerations effect
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[0].effect
value: "Execute"
- it: checks tolerations operator
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[0].operator
value: "Equal"
- it: checks tolerations tolerationSeconds
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[0].tolerationSeconds
value: 3600
- it: checks tolerations key
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600,key2=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[1].key
value: "key2"
- it: checks tolerations effect
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600,key2=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[1].effect
value: "Execute"
- it: checks tolerations operator
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600,key2=Equal:value1:Execute:3600"
asserts:
- equal:
path: spec.template.spec.tolerations[1].operator
value: "Equal"
- it: checks tolerations tolerationSeconds
set:
calyptiaTolerations: "key1=Equal:value1:Execute:3600,key2=Equal:value1:Execute:3605"
asserts:
- equal:
path: spec.template.spec.tolerations[1].tolerationSeconds
value: 3605
- it: checks tolerations exists
set:
calyptiaTolerations: "=Exists::"
asserts:
- equal:
path: spec.template.spec.tolerations[0].operator
value: "Exists"
3 changes: 2 additions & 1 deletion charts/core-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ images:
operator:
registry: ghcr.io
repository: calyptia/core-operator
tag: 3.5.0
tag: 3.7.0
pullSecrets: []
hotReload:
registry: ghcr.io
Expand All @@ -18,6 +18,7 @@ podLabels: {}
nameOverride: ""
fullnameOverride: ""
namespaceOverride: ""
calyptiaTolerations: ""
serviceAccount:
create: true
name: ""
Expand Down