Docker Networking Issue to connect Other container

0

Recently I have been worked on two-tier application deployment so I created two different docker containers and first is MySQL container and the rest is just a notepad project container so, I saw that both docker containers have interconnected with each others and I created a docker network to interconnected each others.

But both containers have not connected each others so, anyone can suggested me which docker network are suitable for this condition, I have created (Bridge network) that is correct for this scenario based

profile picture
質問済み 3ヶ月前367ビュー
1回答
0

Hello Amit,

Your network choice is correct for this scenario. You might want to double-check if you specified the same network name when creating both containers. Typos or inconsistencies can lead to connectivity issues. Also, Ensure you've correctly mapped the port used by your Node.js project to access the MySQL database within the network. Lastly you can use docker-compose for better management of multiple containers

Thanks

回答済み 3ヶ月前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ