Try using docker link: Docs
Suppose you have containers A and B, so to call B from A define a link via task definition UI. Container name should be B, alias B. It can be done in Container Network Settings.