version: '3.7'
services:
translate:
restart: always
# Docker file here: https://github.com/mashirozx/google-translate-server/blob/master/Dockerfile
image: mashirozx/google-translate-server:latest
ports:
- "127.0.0.1:30031:30031"
command: "npm start -- --domain ${DOMAIN:-cn}"
networks:
- external_network
- internal_network
app:
image: app:dev
networks:
- external_network
- internal_network
depends_on:
- translate
links:
- "translate:translationserver"
In app
container, both hostname translate
and translationserver
is unable to resolve, and I tried to use the server public IP, http://public.IP:30031 is accessible in app
. SO the problem is the hostname not resolved in app
container.
Same question, but no one solve my problem: