Add configurable ingress, rename all files to .yaml for conformity.

This commit is contained in:
Shane Lindsay
2024-09-29 23:22:54 -07:00
parent c62e37d16f
commit 005d53cce7
9 changed files with 81 additions and 10 deletions
+1 -1
View File
@@ -2,7 +2,7 @@ apiVersion: v2
name: postiz-app
description: A Social Media Scheduling App
type: application
version: 1.0.1
version: 1.0.2
appVersion: "1.3.0"
keywords:
- social media
@@ -0,0 +1,44 @@
{{- if .Values.ingress.enabled }}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ include "postiz.fullname" . }}
labels:
{{- include "postiz.labels" . | nindent 4 }}
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.ingress.className }}
ingressClassName: {{ .Values.ingress.className }}
{{- end }}
{{- if .Values.ingress.tls }}
tls:
{{- range .Values.ingress.tls }}
- hosts:
{{- range .hosts }}
- {{ . | quote }}
{{- end }}
secretName: {{ .secretName }}
{{- end }}
{{- end }}
rules:
{{- range .Values.ingress.hosts }}
- host: {{ .host | quote }}
http:
paths:
{{- range .paths }}
- path: {{ .path }}
pathType: {{ .pathType }}
backend:
service:
name: {{ include "postiz.fullname" $ }}
port:
number: {{ .port }}
{{- end }}
{{- end }}
{{- if .Values.ingress.extraRules }}
{{- toYaml .Values.ingress.extraRules | nindent 4 }}
{{- end }}
{{- end }}
+9 -2
View File
@@ -25,15 +25,22 @@ service:
port: 80
ingress:
enabled: false
enabled: false # Disabled by default
className: ""
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
pathType: Prefix
port: 80
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local
extraRules: []
resources: {}