Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ngrok internal error when using ReplacePrefixMatch path filter #498

Open
iliya-malecki opened this issue Nov 9, 2024 · 1 comment
Open
Labels
area/controller Issues dealing with the controller bug Something isn't working needs-triage Issues that need triage

Comments

@iliya-malecki
Copy link

Kubernetes Version

Client Version: v1.30.1 Kustomize Version: v5.0.4-0.20230601165947-6ce0bf390ce3 Server Version: v1.30.0

Helm Chart Version

NAME NAMESPACE REVISION UPDATED STATUS CHART APP VERSION ngrok-ingress-controller default 1 2024-11-09 00:17:29.806269035 +0100 CET deployed kubernetes-ingress-controller-0.15.0 0.12.2

Operator Configuration

error: the server doesn't have a resource type "OperatorConfigurations"

System Info

Linux user-ThinkPad-E15-Gen-4 6.8.0-47-generic #47~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Oct 2 16:16:55 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

Kubernetes Logs

❯ kubectl logs -l app.kubernetes.io/name=kubernetes-ingress-controller

{"level":"info","ts":"2024-11-09T14:03:51Z","logger":"cache-store-driver","msg":"sync start"}
{"level":"info","ts":"2024-11-09T14:03:51Z","logger":"cache-store-driver","msg":"syncing driver state!!"}
{"level":"info","ts":"2024-11-09T14:03:51Z","logger":"cache-store-driver","msg":"sync done"}
{"level":"info","ts":"2024-11-09T14:03:52Z","logger":"controllers.https-edge","msg":"Got existing route","v1alpha1.HTTPSEdge":{"name":"mlflow-route-8qjrc","namespace":"default"},"route.match":"/mlflow","route.match_type":"path_prefix","ngrok.route.id":"edghtsrt_2oc6yIt6l0CEl34y5cCcCqqU6Tu"}
{"level":"info","ts":"2024-11-09T14:03:52Z","logger":"controllers.https-edge","msg":"Applying route modules","v1alpha1.HTTPSEdge":{"name":"mlflow-route-8qjrc","namespace":"default"},"route.match":"/mlflow","route.match_type":"path_prefix","ngrok.route.id":"edghtsrt_2oc6yIt6l0CEl34y5cCcCqqU6Tu"}
{"level":"info","ts":"2024-11-09T14:03:52Z","logger":"controllers.https-edge","msg":"Updating Policy module","v1alpha1.HTTPSEdge":{"name":"mlflow-route-8qjrc","namespace":"default"},"route.match":"/mlflow","route.match_type":"path_prefix","ngrok.route.id":"edghtsrt_2oc6yIt6l0CEl34y5cCcCqqU6Tu"}
{"level":"info","ts":"2024-11-09T14:03:52Z","logger":"controllers.https-edge","msg":"Updating route","v1alpha1.HTTPSEdge":{"name":"mlflow-route-8qjrc","namespace":"default"},"route.match":"/mlflow","route.match_type":"path_prefix","ngrok.route.id":"edghtsrt_2oc6yIt6l0CEl34y5cCcCqqU6Tu","ngrok.backend.id":"bkdtg_2oc9WVpXdqgAOJkFCaOS0JlfJ0p"}
{"level":"info","ts":"2024-11-09T14:03:53Z","logger":"controllers.https-edge","msg":"Updated route","v1alpha1.HTTPSEdge":{"name":"mlflow-route-8qjrc","namespace":"default"},"route.match":"/mlflow","route.match_type":"path_prefix","ngrok.route.id":"edghtsrt_2oc6yIt6l0CEl34y5cCcCqqU6Tu"}

Helm Chart configuration


apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
  name: mlflow-route
  namespace: default
spec:
  parentRefs:
    - kind: Gateway
      name: mlflow-gateway
      namespace: default
  hostnames:
    - {{ .Values.api.ingress.host }}
  rules:
    - matches:
        - path:
            type: PathPrefix
            value: /mlflow
      filters:
        - type: URLRewrite
          urlRewrite:
            path:
              type: ReplacePrefixMatch
              replacePrefixMatch: "/"
      backendRefs:
        - name: echo-server
          kind: Service
          port: 80

What happened

When i visit the hostname/mlflow, i get ngrok internal error. This only happens if i specify the ReplacePrefixMatch

What you think should happen instead

It should apply the url rewrite and my service should get the request

How to reproduce

i am an ML engineer so its hopeless for me to attempt building a reprex without guidance, sorry

@iliya-malecki iliya-malecki added area/controller Issues dealing with the controller bug Something isn't working needs-triage Issues that need triage labels Nov 9, 2024
@iliya-malecki
Copy link
Author

for anyone confused by echo-server behind a route named mlflow-route, it is caused by sporadic debugging :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/controller Issues dealing with the controller bug Something isn't working needs-triage Issues that need triage
Projects
None yet
Development

No branches or pull requests

1 participant