Can't connect to Docker deployment

I can’t seem to connect to my GRPC service deployed with Docker. I’m listening on :50051 and have EXPOSE 50051/tcp in my Dockerfile. My fly.toml includes

[[services]]
  internal_port = 50051
  protocol = "tcp"

  [services.concurrency]
    hard_limit = 25
    soft_limit = 20
    type = "connections"

  [[services.ports]]
    handlers = ["tls"]
    port = 443

and I saw the 443->50051 message in the deployment.

However when running ghz, it indicates that the connection to 443 gets reset by the peer immediately. Did I miss something else that needed to be configured?

This looks reasonable, but gRPC is a bit finicky about TLS and ALPN. Are you able to connect over plaintext if you add, like, port 80 with no handlers?

No, I’m not. I tried with this config

[[services]]
  internal_port = 50051
  processes = ["cdn"]
  protocol = "tcp"

  [services.concurrency]
    hard_limit = 25
    soft_limit = 20
    type = "connections"

  [[services.ports]]
    port = 50051

  [[services.tcp_checks]]
    grace_period = "1s"
    interval = "15s"
    restart_limit = 0
    timeout = "2s"

But ghz reports connection closed for both via the assigned subdomain and ip address

Error distribution:
  [200]   rpc error: code = Unavailable desc = connection closed

I can confirm when running the Dockerfile locally with

docker run -p 50051:50051/tcp --rm $(docker build -q .)

that everything works and ghz successfully connects.