Merge pull request #8 from Intreecom/feature/extra-manifests
feature: capability to add extra kubernetes manifests
This commit is contained in:
@ -8,6 +8,7 @@ metadata:
|
|||||||
spec:
|
spec:
|
||||||
{{- if not .Values.autoscaling.enabled }}
|
{{- if not .Values.autoscaling.enabled }}
|
||||||
replicas: {{ .Values.replicaCount }}
|
replicas: {{ .Values.replicaCount }}
|
||||||
|
revisionHistoryLimit: {{ .Values.revisionHistoryLimit | default 5 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.updateStrategy }}
|
{{- with .Values.updateStrategy }}
|
||||||
strategy:
|
strategy:
|
||||||
@ -49,7 +50,13 @@ spec:
|
|||||||
{{- with .Values.probes.readiness }}
|
{{- with .Values.probes.readiness }}
|
||||||
readinessProbe: {{ . | toYaml | nindent 12 }}
|
readinessProbe: {{ . | toYaml | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- with .Values.probes.startup }}
|
||||||
|
startupProbe: {{ . | toYaml | nindent 12 }}
|
||||||
|
{{- end }}
|
||||||
{{- include "py-app.envs" . | indent 10 -}}
|
{{- include "py-app.envs" . | indent 10 -}}
|
||||||
|
{{- with .Values.securityContext }}
|
||||||
|
securityContext: {{ . | toYaml | nindent 12 }}
|
||||||
|
{{- end }}
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.resources | nindent 12 }}
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
|
|
||||||
|
6
charts/py-app/templates/extra-objects.yaml
Normal file
6
charts/py-app/templates/extra-objects.yaml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
{{- if .Values.extraManifests }}
|
||||||
|
{{- range .Values.extraManifests }}
|
||||||
|
---
|
||||||
|
{{ toYaml . }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
12
charts/py-app/templates/limitrange.yaml
Normal file
12
charts/py-app/templates/limitrange.yaml
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
{{- if .Values.limitRange.create }}
|
||||||
|
apiVersion: v1
|
||||||
|
kind: LimitRange
|
||||||
|
metadata:
|
||||||
|
name: {{ include "py-app.fullname" . }}
|
||||||
|
labels:
|
||||||
|
{{- include "py-app.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
{{- with .Values.limitRange.limits }}
|
||||||
|
limits: {{ . | toYaml | nindent 2 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end -}}
|
@ -33,5 +33,5 @@ spec:
|
|||||||
command: {{ .Values.taskiq.schedulerCmd | toYaml | nindent 10 }}
|
command: {{ .Values.taskiq.schedulerCmd | toYaml | nindent 10 }}
|
||||||
{{- include "py-app.envs" . | indent 10 -}}
|
{{- include "py-app.envs" . | indent 10 -}}
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.resources | nindent 12 }}
|
{{- toYaml .Values.taskiq.resources | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -39,5 +39,5 @@ spec:
|
|||||||
command: {{ .Values.taskiq.workerCmd | toYaml | nindent 10 }}
|
command: {{ .Values.taskiq.workerCmd | toYaml | nindent 10 }}
|
||||||
{{- include "py-app.envs" . | indent 10 -}}
|
{{- include "py-app.envs" . | indent 10 -}}
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.resources | nindent 12 }}
|
{{- toYaml .Values.taskiq.resources | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -30,6 +30,7 @@ ttlSecondsAfterFinished: 3600
|
|||||||
taskiq:
|
taskiq:
|
||||||
workerCmd: []
|
workerCmd: []
|
||||||
schedulerCmd: []
|
schedulerCmd: []
|
||||||
|
resources: {}
|
||||||
workers: 1
|
workers: 1
|
||||||
autoscaling:
|
autoscaling:
|
||||||
enabled: false
|
enabled: false
|
||||||
@ -125,3 +126,14 @@ autoscaling:
|
|||||||
maxReplicas: 20
|
maxReplicas: 20
|
||||||
targetCPUUtilizationPercentage: 80
|
targetCPUUtilizationPercentage: 80
|
||||||
# targetMemoryUtilizationPercentage: 80
|
# targetMemoryUtilizationPercentage: 80
|
||||||
|
|
||||||
|
limitRange:
|
||||||
|
create: false
|
||||||
|
# limits:
|
||||||
|
# - default:
|
||||||
|
# memory: 700Mi
|
||||||
|
# defaultRequest:
|
||||||
|
# cpu: 50m
|
||||||
|
# memory: 500Mi
|
||||||
|
# type: Container
|
||||||
|
extraManifests: []
|
Reference in New Issue
Block a user