Docker Community Forums

Share and learn in the Docker community.

Wildfly container can't recognize the mariadb container host name

docker

(Gladiator67) #1

My os is CentOS 7 and I am using Eclipse JBossTools plugin including Docker Tooling. I have 2 running container where one is wildfly 10 and the other is mariadb. Both are working successfully but link of both container is failed. When connection request from wildfly is sent, connection is refused. It throws the following exception,

ERROR [stderr] (default task-1) Caused by: java.net.UnknownHostException: dockerhost: unknown error

However , in database development perspective of eclipse ide, the following jdbc url to mariadb container is working,

jdbc:mysql://dockerhost:3306/test?useUnicode=true&characterEncoding=utf8

My host name is dockerhost.
I have no idea what is the the problem.
Your advice will be deeply appreciated! Thanks for reading


(Richardpayne) #2

Can you post your run commands for both containers?