superlint/test/linters/checkov/good/good_chart/templates/deployment.yaml
2024-06-07 15:06:55 +00:00

39 lines
1.2 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: test-deployment
namespace: test
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
app: test
template:
metadata:
labels:
app: test
spec:
serviceAccountName: {{ .Values.serviceAccount.name }}
automountServiceAccountToken: {{ .Values.serviceAccount.automount }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}@{{ .Values.image.digest }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: {{ .Values.service.port }}
protocol: TCP
livenessProbe:
httpGet:
path: /
port: http
readinessProbe:
httpGet:
path: /
port: http
resources:
{{- toYaml .Values.resources | nindent 12 }}