Deployed services can't call each other?

Hello,

I’ve deployed two very simple web services (Go application, deployed with Dockerfile) and wanted to test whether one service can call the other with a rest/HTTP call.
I used the address I got after the deployment (…fly.dev), but it was unsuccessful, so one app can’t call the other.
Is there any solution for this?

Fly machines run inside a private network, and DNS is set up so that you can find other machines on the same network. For example, if those are two separate fly apps they can find each other by using <appname>.internal as the hostname. For more details, see Private Networking · Fly Docs

1 Like

Thank you for the answer.

I tried with ‘.internal/’ and with ‘.internal:8080/’ as well but none was working.
Do I miss something?

But if I ssh into that application and curl it, it works…

you need to put the appname before the dot.

of course I’ve put it appname.internal:8080/customerpath

somehow the call what my http client is making is not suitable here.
I tested it at my computer and in local with different ports it works well.

Double check that your app isn’t trying to use https?

If you are able to ssh into that application and curl, then your app should be able to access that endpoint too.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.