Add Tornjak ingress (#16)

Co-authored-by: Marco Franssen <[email protected]>
This commit is contained in:
Mariusz Sabath
2023-10-09 11:31:55 +00:00
committed by GitHub
co-authored by Marco Franssen
parent 8f1bfc16ad
commit 03ff618958
6 changed files with 86 additions and 3 deletions
@@ -267,6 +267,12 @@ In order to run Tornjak with simple HTTP Connection only, make sure you don't cr
| `tornjak.service.ports.http` | Insecure port for tornjak service | `10000` |
| `tornjak.service.ports.https` | Secure port for tornjak service | `10443` |
| `tornjak.service.annotations` | Annotations for the service | `{}` |
| `tornjak.ingress.enabled` | Flag to enable ingress for Tornjak backend service | `false` |
| `tornjak.ingress.className` | Ingress class name for Tornjak backend service | `""` |
| `tornjak.ingress.annotations` | Annotations for Tornjak backend service | `{}` |
| `tornjak.ingress.tlsBackendPort` | Flag to enable TLS on the ingress Tornjak backend service | `false` |
| `tornjak.ingress.hosts` | Host paths for ingress Tornjak backend service | `[]` |
| `tornjak.ingress.tls` | Secrets containing TLS certs to enable https on ingress | `[]` |
| `tornjak.startupProbe.failureThreshold` | Failure threshold count | `3` |
| `tornjak.startupProbe.initialDelaySeconds` | Initial delay seconds | `5` |
| `tornjak.startupProbe.periodSeconds` | Period seconds | `10` |
@@ -0,0 +1,16 @@
{{- if .Values.tornjak.ingress.enabled -}}
{{- $fullName := include "spire-tornjak.fullname" . -}}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ $fullName }}
namespace: {{ include "spire-server.namespace" . }}
labels:
{{ include "spire-server.labels" . | nindent 4}}
{{- with .Values.tornjak.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{ include "spire-lib.ingress-spec" (dict "ingress" .Values.tornjak.ingress "svcName" (include "spire-tornjak.servicename" .) "port" "tornjak-srv-http") | nindent 2 }}
{{- end }}
@@ -562,6 +562,27 @@ tornjak:
## @param tornjak.service.annotations [object] Annotations for the service
annotations: {}
## @param tornjak.ingress.enabled Flag to enable ingress for Tornjak backend service
## @param tornjak.ingress.className Ingress class name for Tornjak backend service
## @param tornjak.ingress.annotations [object] Annotations for Tornjak backend service
## @param tornjak.ingress.tlsBackendPort Flag to enable TLS on the ingress Tornjak backend service
## @param tornjak.ingress.hosts [array] Host paths for ingress Tornjak backend service
ingress:
enabled: false
className: ""
annotations: {}
tlsBackendPort: false
hosts:
- host: tornjak-backend.example.org
paths:
- path: /
pathType: Prefix
## @param tornjak.ingress.tls [array] Secrets containing TLS certs to enable https on ingress
tls: []
# - secretName: chart-example-tls
# hosts:
# - tornjak-backend.example.org
## @param tornjak.startupProbe.failureThreshold Failure threshold count
## @param tornjak.startupProbe.initialDelaySeconds Initial delay seconds
## @param tornjak.startupProbe.periodSeconds Period seconds