Access gRPC server through Traefikee

Hi,
I've deployed Traefikee in a Kubernetes cluster and configured a service and a router following the gRPC section of the Traefik docs: Traefik Proxy gRPC Examples - Traefik

  • I have a gRPC server at grpc.example-url.com:8080 which is answering. Tested it with grpcurl.
    grpcurl -vv -plaintext example-url.com:8080 helloworld.Greeter/SayHello

  • Configured the service and router like the documentation.

  • Configured grpc.fronturl.com as the Host and h2c://grpc.example-url.com:8080 as backend.

However, when I access grpc.fronturl.com the server is not responding.

Not sure if I did something wrong or I misunderstood something.

Thank you for your help.

Hi @Conacious! Thanks for using Traefik!

Could you post your configuration, and could you run Traefik in DEBUG mode and post the logs?

The static configuration that I'm using:

    entryPoints:
      http:
        address: ":80"
      https:
        address: ":443"

    log:
      level: DEBUG

    api:
      dashboard: true
      insecure: true

    providers:
      kubernetesIngress: {}
      kubernetesCRD: {}
      file:
        directory: /var/run/traefikee/config

    accessLog: {}

    http:
      routers:
        routerTest:
          service: srv-grpc
          rule: Host(`${local.grpc_endpoint}`)
      services:
        srv-grpc:
          loadBalancer:
            passHostHeader: false
            servers:
              - url: "h2c://${local.endpoints.grpc_api}:8080/"
        user-api:
          loadBalancer:
            passHostHeader: false
            servers:
              - url: "https://${local.endpoints.user_api}/"

And when I test the frontend endpoint with grpcurl:

grpcurl -vv -plaintext grpc.frontend.com:80 helloworld.Greeter/SayHello

I can see the following logs

│ proxy 10.11.152.82 - - [02/Feb/2023:15:50:12 +0000] "POST /grpc.reflection.v1alpha.ServerReflection/ServerReflectionInfo HTTP/1.1" 200 358 "-" "-" 1633 "routerTest@file" "h2c://grpc.example.com: │

But I get a timeout in the cli

Error invoking method "helloworld.Greeter/SayHello": rpc error: code = Unavailable desc = failed to query for service descriptor "helloworld.Greeter": unexpected HTTP status code received from server: 504 (Gateway Timeout); malformed header: missing HTTP content-type

02/02 15:59:19 httputil: ReverseProxy read error during body copy: unexpected EOF