Compare commits

..

2 Commits

Author SHA1 Message Date
Jonas Forsberg
4f2a9ba9b7 . 2024-10-19 11:23:43 +02:00
Jonas Forsberg
dd11ed2197 fixed default varable 2024-10-19 11:09:04 +02:00
5 changed files with 23 additions and 11 deletions

View File

@ -45,7 +45,7 @@ The following table lists the configurable parameters of the Lib chart and their
| `autoscaling.targetCPUUtilizationPercentage` | | `80` |
| `secrets` | Secrets that needs to be created | `{}` |
| `configs` | ConfigMaps that needs to be created | `{}` |
| `env.TZ` | | `"Europe/Stockholm"` |
| `env` | environment variables the controller should have | `[{"name": "TZ", "value": "Europe/Stockholm"}]` |
| `volumes` | | `[]` |
| `volumeMounts` | | `[]` |
| `volumeClaimTemplates` | used for statefulset https://kubernetes.io/docs/concepts/workloads/controllers/statefulset | `[]` |

View File

@ -44,18 +44,23 @@ spec:
{{- range $k, $v := $values.ports }}
- name: {{ $k }}
containerPort: {{ default $v.port $v.targetPort }}
protocol: {{ default "HTTP" $v.protocol }}
{{- end -}}
{{- end -}}
{{- end }}
env:
{{- include "lib.environmentVariables" . | default "[]" | nindent 12 }}
{{- with .Values.livenessProbe }}
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.readinessProbe }}
readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.resources }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumeMounts }}
volumeMounts:
{{- toYaml . | nindent 12 }}

View File

@ -19,7 +19,7 @@ spec:
{{- range $k, $v := $values.ports }}
- port: {{ $v.port }}
targetPort: {{ default $v.port $v.targetPort }}
protocol: {{ default "HTTP" $v.protocol }}
protocol: {{ default "TCP" $v.protocol }}
name: {{ $k }}
{{- end }}
selector:

View File

@ -46,18 +46,24 @@ spec:
{{- range $k, $v := $values.ports }}
- name: {{ $k }}
containerPort: {{ $v.targetPort | default $v.port }}
protocol: {{ $v.protocol }}
protocol: {{ default "TCP" $v.protocol }}
{{- end -}}
{{- end -}}
{{- end }}
env:
{{- include "lib.environmentVariables" . | default "[]" | nindent 12 }}
{{- with .Values.livenessProbe }}
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.readinessProbe }}
readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.resources }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
volumeMounts:
{{- range $i, $values := .Values.volumeClaimTemplates }}
- name: {{ $values.name }}

View File

@ -99,7 +99,8 @@ configs: {} # ConfigMaps that needs to be created
# KEY: VALUE
env: # environment variables the controller should have
TZ: Europe/Stockholm
- name: TZ
value: Europe/Stockholm
# Additional volumes on the output Deployment definition.
volumes: []
# - name: foo