Skip to content

Commit

Permalink
[bitnami/matomo] Added the ability to specify a nodeSelector and tain…
Browse files Browse the repository at this point in the history
…ts for cronjob (#25383)

* Added the ability to specify a nodeSelector and taints for cronjob

Signed-off-by: Denis Arslanbekov <[email protected]>

* Update README.md

Signed-off-by: Denis Arslanbekov <[email protected]>

* Update bitnami/matomo/Chart.yaml

Co-authored-by: Miguel Ruiz <[email protected]>
Signed-off-by: Denis Arslanbekov <[email protected]>

---------

Signed-off-by: Denis Arslanbekov <[email protected]>
Signed-off-by: Denis Arslanbekov <[email protected]>
Signed-off-by: Miguel Ruiz <[email protected]>
Co-authored-by: Miguel Ruiz <[email protected]>
  • Loading branch information
arslanbekov and migruiz4 authored May 7, 2024
1 parent 1d37888 commit 1b4d6a1
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 1 deletion.
2 changes: 1 addition & 1 deletion bitnami/matomo/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ maintainers:
name: matomo
sources:
- https://github.com/bitnami/charts/tree/main/bitnami/matomo
version: 7.0.5
version: 7.1.0
4 changes: 4 additions & 0 deletions bitnami/matomo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,8 @@ helm install my-release --set persistence.existingClaim=PVC_NAME oci://REGISTRY_
| `cronjobs.taskScheduler.schedule` | Kubernetes CronJob schedule | `*/5 * * * *` |
| `cronjobs.taskScheduler.suspend` | Whether to create suspended CronJob | `false` |
| `cronjobs.taskScheduler.affinity` | Affinity for CronJob pod assignment | `{}` |
| `cronjobs.taskScheduler.nodeSelector` | Node labels for CronJob pod assignment. Evaluated as a template. | `{}` |
| `cronjobs.taskScheduler.tolerations` | Tolerations for CronJob pod assignment | `[]` |
| `cronjobs.taskScheduler.command` | Override default container command (useful when using custom images) | `[]` |
| `cronjobs.taskScheduler.args` | Override default container args (useful when using custom images) | `[]` |
| `cronjobs.taskScheduler.containerSecurityContext.enabled` | Enabled containers' Security Context | `true` |
Expand Down Expand Up @@ -407,6 +409,8 @@ helm install my-release --set persistence.existingClaim=PVC_NAME oci://REGISTRY_
| `cronjobs.archive.schedule` | Kubernetes CronJob schedule | `*/5 * * * *` |
| `cronjobs.archive.suspend` | Whether to create suspended CronJob | `false` |
| `cronjobs.archive.affinity` | Affinity for CronJob pod assignment | `{}` |
| `cronjobs.archive.tolerations` | Tolerations for CronJob pod assignment | `[]` |
| `cronjobs.archive.nodeSelector` | Node labels for CronJob pod assignment. Evaluated as a template. | `{}` |
| `cronjobs.archive.command` | Override default container command (useful when using custom images) | `[]` |
| `cronjobs.archive.args` | Override default container args (useful when using custom images) | `[]` |
| `cronjobs.archive.containerSecurityContext.enabled` | Enabled containers' Security Context | `true` |
Expand Down
12 changes: 12 additions & 0 deletions bitnami/matomo/templates/cronjob.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ spec:
{{- if .Values.cronjobs.archive.affinity }}
affinity: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.archive.affinity "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.cronjobs.archive.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.archive.nodeSelector "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.cronjobs.archive.tolerations }}
tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.archive.tolerations "context" $) | nindent 12 }}
{{- end }}
initContainers:
{{ include "matomo.initContainers" . | nindent 12 }}
{{- if .Values.cronjobs.archive.podSecurityContext.enabled }}
Expand Down Expand Up @@ -203,6 +209,12 @@ spec:
{{- if .Values.cronjobs.taskScheduler.affinity }}
affinity: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.taskScheduler.affinity "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.cronjobs.taskScheduler.nodeSelector }}
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.taskScheduler.nodeSelector "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.cronjobs.taskScheduler.tolerations }}
tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.cronjobs.taskScheduler.tolerations "context" $) | nindent 12 }}
{{- end }}
restartPolicy: OnFailure
initContainers:
{{ include "matomo.initContainers" . | nindent 12 }}
Expand Down
16 changes: 16 additions & 0 deletions bitnami/matomo/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -963,6 +963,14 @@ cronjobs:
## @param cronjobs.taskScheduler.affinity Affinity for CronJob pod assignment
##
affinity: {}
## @param cronjobs.taskScheduler.nodeSelector Node labels for CronJob pod assignment. Evaluated as a template.
## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
##
nodeSelector: {}
## @param cronjobs.taskScheduler.tolerations Tolerations for CronJob pod assignment
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
## @param cronjobs.taskScheduler.command Override default container command (useful when using custom images)
##
command: []
Expand Down Expand Up @@ -1054,6 +1062,14 @@ cronjobs:
## @param cronjobs.archive.affinity Affinity for CronJob pod assignment
##
affinity: {}
## @param cronjobs.archive.tolerations Tolerations for CronJob pod assignment
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
## @param cronjobs.archive.nodeSelector Node labels for CronJob pod assignment. Evaluated as a template.
## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
##
nodeSelector: {}
## @param cronjobs.archive.command Override default container command (useful when using custom images)
##
command: []
Expand Down

0 comments on commit 1b4d6a1

Please sign in to comment.