Add service and ingress to the template

This commit is contained in:
dvirlabs 2025-07-10 13:01:53 +03:00
parent d019e75b14
commit 0964baf610
2 changed files with 42 additions and 0 deletions

View File

@ -0,0 +1,27 @@
{{- if .Values.ingress.enabled }}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: tunedrop
annotations:
{{- range $key, $val := .Values.ingress.annotations }}
{{ $key }}: {{ $val | quote }}
{{- end }}
spec:
ingressClassName: {{ .Values.ingress.className }}
rules:
{{- range .Values.ingress.hosts }}
- host: {{ .host }}
http:
paths:
{{- range .paths }}
- path: {{ .path }}
pathType: {{ .pathType }}
backend:
service:
name: tunedrop
port:
number: 80
{{- end }}
{{- end }}
{{- end }}

View File

@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
name: tunedrop
labels:
app: tunedrop
spec:
type: ClusterIP
selector:
app: tunedrop
ports:
- port: 80
targetPort: 8000
protocol: TCP
name: http