Service cannot reach itself via host-port combo

I have observed that it’s not possible for a service to be able to reach itself via its own internal host-port address, eg. http://api-l4dg:3001. As an example, from the shell of api-l4dg:

render@srv-c0abfrlua9vt7i8f5v2g-b6bfd4d64-s8cnw:~/project/src$ curl --max-time 1 http://api-l4dg:3001/graphql
curl: (28) Connection timed out after 1001 milliseconds

This seems like a bug to me. Is this behavior intentional?

Try using port 10000 (the default port for Render services). We recently discovered a bug where sometimes the service address is reported incorrectly in the dashboard. We’ll get this fixed soon.

Does this also affect render.yaml forms like

      - key: API_HOSTPORT
        fromService:
          name: api
          type: web
          property: hostport

I have recently discovered that two of my services from within the same render.yaml project cannot seem to reach each other. Could that be related?

curl api-l4dg:10000/graphql does work.

1 Like

Does this also affect render.yaml forms

For web services, yes, it could be related. Ports for private services should be working properly. We’ll keep you posted on the fix.

Any ETA on a fix for this? Will port 10000 stop working once the correct port starts working?

We’re reviewing the suggested change and how it might impact existing users. We’ll ensure that if you use 10000 that it’ll continue to work.

1 Like