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

ingress doesn't return static resources #364

Closed
survivant opened this issue Apr 8, 2021 · 6 comments · Fixed by #511
Closed

ingress doesn't return static resources #364

survivant opened this issue Apr 8, 2021 · 6 comments · Fixed by #511
Assignees
Labels
type/bug Something isn't working
Projects
Milestone

Comments

@survivant
Copy link
Contributor

I wanted to add Ingress for kafka-ui but it's not working (but working fine with the nodePort. What is missing to get it to work with Ingress ?

http://10.1.34.6/kafka-ui

image

here my config

kafka-ui:
  enabled: true
  service:
    type: NodePort
    nodePort: 32002

  envs:
    config:
      KAFKA_CLUSTERS_0_NAME: local
      KAFKA_CLUSTERS_0_BOOTSTRAPSERVERS: kafka-cp-kafka:9092
      KAFKA_CLUSTERS_0_ZOOKEEPER: kafka-cp-zookeeper:2181
      KAFKA_CLUSTERS_0_SCHEMAREGISTRY: http://kafka-cp-schema-registry:8081
      KAFKA_CLUSTERS_0_KAFKACONNECT_0_ADDRESS: http://kafka-cp-kafka-connect:8083

  ingress:
    annotations:
      nginx.ingress.kubernetes.io/rewrite-target: /$2
      nginx.ingress.kubernetes.io/ssl-redirect: "false"
    enabled: true
    hosts:
    - host: ""
      paths:
      - /kafka-ui(/|$)(.*)

here the ingress generated

...
spec:
  rules:
  - http:
      paths:
      - backend:
          service:
            name: kafka-ui
            port:
              number: 80
        path: /kafka-ui(/|$)(.*)
        pathType: ImplementationSpecific

I can compare it with granafa
http://10.1.34.6/grafana redirect to http://10.1.34.6/grafana/login

....
spec:
  rules:
  - http:
      paths:
      - backend:
          service:
            name: monitoring-stack-grafana
            port:
              number: 80
        path: /grafana(/|$)(.*)
        pathType: Prefix

is it a resource mapping that is missing in Spring boot to handle that ?

@RustamGimadiev
Copy link
Contributor

Hi @survivant, thanks for opening this issue, we able to reproduce that behavior of the ingress and has looking for a solution, unfortunately, we cannot provide any workaround

@RustamGimadiev RustamGimadiev self-assigned this Apr 12, 2021
@RustamGimadiev RustamGimadiev added the type/bug Something isn't working label Apr 12, 2021
@survivant
Copy link
Contributor Author

@RustamGimadiev thanks for the feedback. the workaround that I use, if a nodePort for now.

@germanosin germanosin added this to To do in Release 0.1 via automation May 7, 2021
@germanosin germanosin added this to the 0.1 milestone May 7, 2021
@andormarkus
Copy link
Contributor

Hi @RustamGimadiev

We are using AWS EKS, our ingress controller is aws-load-balancer-controller which does not support rewrite-target like nginx.ingress does.

We are doing path based fanout like foobaa.com/airflow foobaa.com/kafka foobaa.com/spark, however once I set ingress path to non-root path I can not reach the UI anymore.

Non-working configuration:

ingress:
  enabled: true
  hosts:
    - host:
      paths:
        - /kafkaui/*

Working configuration:

ingress:
  enabled: true
  hosts:
    - host:
      paths:
        - /*

Can you add capability of running on a non-root path either by default or by setting the base path in the configuration?

Thank you!

@RustamGimadiev RustamGimadiev moved this from To do to In Progress in Release 0.1 May 31, 2021
Release 0.1 automation moved this from In Progress to Done Jun 3, 2021
@RustamGimadiev
Copy link
Contributor

Hi, @survivant @andormarkus, now you can use kafka-ui with custom URI prefix, for that please use latest image tag, the example of use described in https://github.com/provectus/kafka-ui/blob/master/docker/kafka-ui-reverse-proxy.yaml

@AydinChavez
Copy link

have same issue, am using helm charts. How can I fix this?

@Haarolean
Copy link
Contributor

have same issue, am using helm charts. How can I fix this?

@AydinChavez please raise a new issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Something isn't working
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

6 participants