I have a python app running and I already managed to expose it through Gateway API and access it through "http:///pythonapp".Next I deployed a Elasticsearch and Kibana instance so I can gain experience in monitoring and in the Elastic Stack, I deployed it using the ECK operator which made it very simple.
The problem is the expose part, while I tested the Gateway and HTTPRoutes configs with a simple html page and my python app and it worked, when I do the same for Kibana instance I keep getting a '503 Service Temporarily Unavailable' error. I checked the status of the route, gateway and Kibana pod and it was all green, I even port-forwarded the Kibana pod and accessed it locally to make sure there wasn't a problem with Kibana.For context I am using NGINX Gateway Fabric for controller of the GW API and got this running on a GCP VM instance with k3s.
Bellow is the code of Kibana deployment and HTTPRoute:
apiVersion: kibana.k8s.elastic.co/v1
kind: Kibana
metadata:
name: kibana
namespace: elastic-system
spec:
version: 9.2.2
count: 1
elasticsearchRef:
name: elastic-monitoring
http:
tls:
selfSignedCertificate:
disabled: true
podTemplate:
spec:
containers:
- name: kibana
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
name: kibana-route
namespace: elastic-system
spec:
parentRefs:
- name: main-gw
namespace: gateway
sectionName: http
rules:
- matches:
- path:
type: PathPrefix
value: /monitoring
filters:
- type: URLRewrite
urlRewrite:
path:
type: ReplacePrefixMatch
replacePrefixMatch: /
backendRefs:
- name: kibana-kb-http
namespace: elastic-system
port: 5601
I´ve also tried to remove the filters section from the HTTPRoute and using basePath in Kibana. Got the same error.I suspect it has something to do with the prefix.
Any help / suggestions to solve this issue?