Skip to content

Commit

Permalink
created specific ingress for requests to api/bootstrap from outside t…
Browse files Browse the repository at this point in the history
…he cluster (#20)

* created specific ingress for requests to api/bootstrap from outside the cluster

Signed-off-by: Savvas Kyriacou <[email protected]>

* Update bootstrap ingress rewrite path

Signed-off-by: Eamonn Mansour <[email protected]>

* Fix webui liveness and readiness probe warnings

Signed-off-by: Eamonn Mansour <[email protected]>

* Update bootstrap ingress name

Signed-off-by: Eamonn Mansour <[email protected]>

---------

Signed-off-by: Savvas Kyriacou <[email protected]>
Signed-off-by: Eamonn Mansour <[email protected]>
Co-authored-by: Eamonn Mansour <[email protected]>
  • Loading branch information
KirbyKatcher and eamansour authored Apr 16, 2024
1 parent 7935679 commit 6b3419d
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 5 deletions.
33 changes: 33 additions & 0 deletions charts/ecosystem/templates/api-bootstrap-ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#
# Copyright contributors to the Galasa project
#
# SPDX-License-Identifier: EPL-2.0
#

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ .Release.Name }}-api-bootstrap
annotations:
{{- with .Values.ingress.annotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
nginx.ingress.kubernetes.io/rewrite-target: /bootstrap/external
spec:
ingressClassName: {{ .Values.ingress.ingressClassName }}
{{- with .Values.ingress.tls }}
tls:
{{- toYaml . | nindent 4 }}
{{- end }}
rules:
- host: {{ .Values.externalHostname }}
http:
paths:
- path: /api/bootstrap
pathType: ImplementationSpecific
backend:
service:
name: {{ .Release.Name }}-api
port:
number: 8080

2 changes: 1 addition & 1 deletion charts/ecosystem/templates/api-ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ spec:
- host: {{ .Values.externalHostname }}
http:
paths:
- path: /api(/|$)(.*)
- path: /api(/|$)((?!bootstrap).*)
pathType: ImplementationSpecific
backend:
service:
Expand Down
6 changes: 2 additions & 4 deletions charts/ecosystem/templates/webui.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,12 @@ spec:
- containerPort: 8080
name: http
livenessProbe:
httpGet:
path: /
tcpSocket:
port: 8080
initialDelaySeconds: 5
periodSeconds: 60
readinessProbe:
httpGet:
path: /
tcpSocket:
port: 8080
initialDelaySeconds: 5
periodSeconds: 10
Expand Down

0 comments on commit 6b3419d

Please sign in to comment.