7

Multi-Domain Docker Containers

 1 year ago
source link: https://carlosvin.github.io/langs/en/posts/reverse-proxy-multidomain-docker/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Use case

We have several server applications in the same development environment, each application is bundled in a Docker container, e.g: "Container A" and "Container B".

With Docker those applications have the same IP address. One way to differentiate and access to an specific application is exposing different ports.

ip

Containers exposing the same IP address and different ports.

But that solution is a little bit confusing, does 8080 mean we are accessing to "application A"?

It would be simpler and easier to remind something like:

domain

Accessing applications by domain name.

Get that extra semantic value is much simpler than I thought at the beginning and you will see below.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK